 In 1881, it signed the Boundary Treaty of 1881 between Chile and Argentina confirming Chilean sovereignty over the Strait of Magellan, but conceding all of oriental Patagonia, and a considerable fraction of the territory it had during colonial times.As a result of the War of the Pacific with Peru and Bolivia (1879–1883), Chile expanded its territory northward by almost one-third and acquired valuable nitrate deposits, the exploitation of which led to an era of national affluence.In the 1870s, the church influence started to diminish slightly with the passing of several laws that took some old roles of the church into the State's hands such as the registry of births and marriages.