summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xsrc/migration-scripts/system/9-to-105
1 files changed, 3 insertions, 2 deletions
diff --git a/src/migration-scripts/system/9-to-10 b/src/migration-scripts/system/9-to-10
index 885ef819f..3c49f0d95 100755
--- a/src/migration-scripts/system/9-to-10
+++ b/src/migration-scripts/system/9-to-10
@@ -24,8 +24,9 @@ if not config.exists(base_level):
sys.exit(0)
else:
for user in config.list_nodes(base_level):
- if config.return_value(base_level + [user, 'level']) == 'operator':
- config.set(base_level + [user, 'level'], value="admin", replace=True)
+ if config.exists(base_level + [user, 'level']):
+ if config.return_value(base_level + [user, 'level']) == 'operator':
+ config.set(base_level + [user, 'level'], value="admin", replace=True)
try:
open(file_name,'w').write(config.to_string())