Enable extensions to provide a default settings dictionary
Review Request #2907 — Created Feb. 20, 2012 and submitted — Latest diff uploaded
When an extension is loaded for the first time it is initialized with an empty settings dictionary. All extension authors must either initialize the settings dictionary and save it, or check at use if the setting exists. This modification allows an extension author to specify a default settings dictionary, which will be used if a key is not present in extension.settings. Instead of copying all defaults, I only reference them when a missing key is accessed. Another option would be to initialize the settings when the extension is loaded. Feel free to suggest other ideas.
Tested in local dev with dummy extensions. Ran djblets unit tests.