Storing and loading of a value is now together on one line, all in the same file. Duplicated code is elliminated.
Added migration method which can migrate the settings layout when new settings layout isn't backwards compatible. No more checking and adding code to be backwards compatible throughout the whole codebase. Migration depends on a version number and is only done once. Multiple migrations can happen after each other when the settings layout is multiple versions behind the current version.
Refactoring of loading and storing settings: