From 62d8a26cd359c101a6ee6c12b2887681653772f0 Mon Sep 17 00:00:00 2001 From: Ram Krishna Verma Date: Wed, 8 Sep 2021 15:18:00 -0400 Subject: Fix sonar issue in policy/gui Issue-ID: POLICY-3077 Change-Id: Ia4a1a12ab286d40205ec5a81d130c4845cd93cea Signed-off-by: Ram Krishna Verma --- .../gui-editor-apex/src/main/resources/webapp/js/ApexPolicyEditForm.js | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/gui-editors/gui-editor-apex/src/main/resources/webapp/js/ApexPolicyEditForm.js b/gui-editors/gui-editor-apex/src/main/resources/webapp/js/ApexPolicyEditForm.js index edaf7b7..df0ddf0 100644 --- a/gui-editors/gui-editor-apex/src/main/resources/webapp/js/ApexPolicyEditForm.js +++ b/gui-editors/gui-editor-apex/src/main/resources/webapp/js/ApexPolicyEditForm.js @@ -440,8 +440,7 @@ function editPolicyForm_activate(parent, operation, policy, tasks, events, conte break; } } - for (i = 0; i < policy.state.entry.length; i++) { - var stateEntry = policy.state.entry[i]; + for (let stateEntry of policy.state.entry) { statename = stateEntry.key; state = stateEntry.value; var stateLI = editPolicyForm_addState(statename, state, createEditOrView, policy, tasks, events, -- cgit 1.2.3-korg