The library luckily survived the violent times of Polish history, such as the Swedish invasion (1656-1660) or the Great Northern War (1700-1721). In 1810, only 2400 volumes were left in stock; at the dissolution of the monastery in 1829, the library, then under the authority of the Head of the city police, was moved to the nearby House of Loreto's order and at the demolition of the monastery in 1838, the books have been placed in a compartment behind the main altar of the Bernardine Church of Our Lady Queen of Peace. They have been then transferred to the cathedral where they survived until 1907.