From 582e2cca42ee69e6da8408e82709afe491d61139 Mon Sep 17 00:00:00 2001 From: Robert Barrow Date: Fri, 31 May 2019 23:25:22 +0100 Subject: [PATCH] fixed issue that prevented you adding params or endpoints when there were none to begin with --- .../discourse/controllers/admin-wizards-api.js.es6 | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/assets/javascripts/discourse/controllers/admin-wizards-api.js.es6 b/assets/javascripts/discourse/controllers/admin-wizards-api.js.es6 index ec4b5170..3787c60e 100644 --- a/assets/javascripts/discourse/controllers/admin-wizards-api.js.es6 +++ b/assets/javascripts/discourse/controllers/admin-wizards-api.js.es6 @@ -11,6 +11,9 @@ export default Ember.Controller.extend({ actions: { addParam() { + if (this.get('api.authParams') == undefined) { + this.set('api.authParams',[]); + }; this.get('api.authParams').pushObject({}); }, @@ -19,6 +22,9 @@ export default Ember.Controller.extend({ }, addEndpoint() { + if (this.get('api.endpoints') == undefined) { + this.set('api.endpoints',[]); + }; this.get('api.endpoints').pushObject({}); },