diff options
author | Alexander Gee <bostwickenator@gmail.com> | 2020-05-24 03:58:55 +0300 |
---|---|---|
committer | Alexander Gee <bostwickenator@gmail.com> | 2020-05-24 05:10:47 +0300 |
commit | 18098ae89364345476a360600baf083d89d0bedf (patch) | |
tree | 055f0a491ecd86138a1c60bb842338da428580dc /plugins/VersionUpgrade | |
parent | e807a086b4c1db930972ad6125f398b9703e4973 (diff) | |
parent | bd7248fe7320ad191043ea14c95d481df35fd214 (diff) |
Use access pattern from PauseAtHeight
Diffstat (limited to 'plugins/VersionUpgrade')
-rw-r--r-- | plugins/VersionUpgrade/VersionUpgrade462to47/VersionUpgrade462to47.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/plugins/VersionUpgrade/VersionUpgrade462to47/VersionUpgrade462to47.py b/plugins/VersionUpgrade/VersionUpgrade462to47/VersionUpgrade462to47.py index 9f99eeec79..3461ead8d2 100644 --- a/plugins/VersionUpgrade/VersionUpgrade462to47/VersionUpgrade462to47.py +++ b/plugins/VersionUpgrade/VersionUpgrade462to47/VersionUpgrade462to47.py @@ -123,12 +123,12 @@ class VersionUpgrade462to47(VersionUpgrade): # Migrate DisplayCompleteOnLCD to DisplayProgressOnLCD if script_id == "DisplayPercentCompleteOnLCD": - script_settings = script_parser.items(script_id) + was_enabled = script_parser[script_id]["TurnOn"] == "true" if "TurnOn" in script_parser[script_id] else False script_parser.remove_section(script_id) script_id = "DisplayProgressOnLCD" script_parser.add_section(script_id) - if (script_settings["TurnOn"] == "true"): + if (was_enabled): script_parser.set(script_id, "time_remaining", "true") script_io = io.StringIO() |