The Five Dynasties and Ten Kingdoms is a period in Chinese history, which began with the fall of the Tang Dynasty and ended with the unification of most of the Han land by the Song Dynasty. The Five Dynasties and Ten Kingdoms are essentially the continuation of the separatist rule in the late Tang Dynasty and the politics of the late Tang Dynasty. After the demise of the Tang Dynasty, the vassal towns in various places established themselves as their own countries. Among them, the countries with stronger military power in North China were collectively referred to as the "Five Dynasties", and some were established by Shatuo.
Although this can only be answered subjectively, most historians believe that the Treaty of Guadalupe was unfair, and that the sole intention of the US was to gain more territory at any expense.