added more functions for local storage