Fix bug when adding op policy 67/106467/1
authorsebdet <sebastien.determe@intl.att.com>
Wed, 22 Apr 2020 21:10:54 +0000 (23:10 +0200)
committersebdet <sebastien.determe@intl.att.com>
Wed, 22 Apr 2020 21:10:54 +0000 (23:10 +0200)
The fix to prevent multiple op policy modle to be inserted introduced another bug, this pr fixes it

Issue-ID: CLAMP-828
Signed-off-by: sebdet <sebastien.determe@intl.att.com>
Change-Id: I90432688df48cbf2b456efae5e4191e2909077cc

ui-react/src/api/LoopService.js

index 3b9ed86..8f9805e 100644 (file)
@@ -233,9 +233,9 @@ export default class LoopService {
                                        return response.text();
                                }
                        })
-                       .then(function (object) {
+                       .catch(function (error) {
                                console.error("Add Operational Policy query failed");
-                               throw new Error(object);
+                               throw new Error(error);
                        })
        }