mirror of
https://github.com/pgadmin-org/pgadmin4.git
synced 2025-02-25 18:55:31 -06:00
Fixed the following SonarQube code smells:
1) Do not use Array index in keys. 2) Unnecessary escape character. 3) Rename this local variable to match the regular expression ^[_a-z][a-z0-9_]*$ 4) Remove the unused local variable.
This commit is contained in:
@@ -564,6 +564,7 @@ def compare_database(params):
|
||||
|
||||
msg = gettext("Successfully compare the specified databases.")
|
||||
total_percent = 100
|
||||
diff_model_obj.set_comparison_info(msg, total_percent)
|
||||
# Update the message and total percentage done in session object
|
||||
update_session_diff_transaction(params['trans_id'], session_obj,
|
||||
diff_model_obj)
|
||||
@@ -626,6 +627,7 @@ def compare_schema(params):
|
||||
|
||||
msg = gettext("Successfully compare the specified schemas.")
|
||||
total_percent = 100
|
||||
diff_model_obj.set_comparison_info(msg, total_percent)
|
||||
# Update the message and total percentage done in session object
|
||||
update_session_diff_transaction(params['trans_id'], session_obj,
|
||||
diff_model_obj)
|
||||
|
@@ -627,7 +627,6 @@ def directory_diff(source_dict, target_dict, ignore_keys=[], difference=None):
|
||||
for index in range(len(source_dict[key])):
|
||||
source = copy.deepcopy(source_dict[key][index])
|
||||
if isinstance(source, list):
|
||||
# TODO
|
||||
pass
|
||||
elif isinstance(source, dict):
|
||||
# Check the above keys are exist in the dictionary
|
||||
|
Reference in New Issue
Block a user