Refactoring of Saving and Loading methods