Improved package restore