Fixed an issue where the local storage hadn't already been created or a model hadn't already been added.