Add sorce upgrade selected keys
This commit is contained in:
parent
d60ff21e26
commit
751d109c2a
|
@ -118,6 +118,7 @@ class Config(object):
|
||||||
# Read the config files
|
# Read the config files
|
||||||
self.__user_config = Utility.load_json(Utility.CONFIG_FILE_PATH)
|
self.__user_config = Utility.load_json(Utility.CONFIG_FILE_PATH)
|
||||||
self.__system_config = Utility.load_json(Utility.SYSTEM_CONFIG_FILE_PATH)
|
self.__system_config = Utility.load_json(Utility.SYSTEM_CONFIG_FILE_PATH)
|
||||||
|
self.__force_upgrade = ['long_breaks', 'short_breaks']
|
||||||
|
|
||||||
if self.__user_config is None:
|
if self.__user_config is None:
|
||||||
Utility.initialize_safeeyes()
|
Utility.initialize_safeeyes()
|
||||||
|
@ -144,7 +145,7 @@ class Config(object):
|
||||||
Merge the dictionaries.
|
Merge the dictionaries.
|
||||||
"""
|
"""
|
||||||
for key in new_dict:
|
for key in new_dict:
|
||||||
if key == "meta":
|
if key == "meta" or key in self.__force_upgrade:
|
||||||
continue
|
continue
|
||||||
if key in old_dict:
|
if key in old_dict:
|
||||||
new_value = new_dict[key]
|
new_value = new_dict[key]
|
||||||
|
|
Loading…
Reference in New Issue