Added a layer of abstraction for local storage