After the irregulars of the League of Prizren were crushed by the Ottomans in 1881, Ali Pasha of Gusinje was arrested. He was released after the Sultan gave general amnesty. Ali Pasha was appointed to the position of mutesarrif of the Ottoman Sanjak of İpek because he did not object the Ottoman rule and maintained a close connection with the Porte throughout the conflict being more concerned to prevent Montenegro to capture Plav and Gusinje. The Ottoman state also gave him forestland for his defense of Gusinje against the Montenegrins and later Ali Pasha sent some Albanian youths from the region for training and service in the place guard of sultan Abdulhamid II. In 1881, during his visit to Istanbul, he was promoted to the rank of beylerbey.