Added some more settings code to attempt to fix an unloadable settings file.