Avoid throwing an error when checking localStorage for settings

[skip ci]