Added package restore function