Refactored the restore function as well and enforced better naming
Added a restore function and renamed the module