aboutsummaryrefslogtreecommitdiffstats
path: root/src/models/Service.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/models/Service.js')
-rw-r--r--src/models/Service.js8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/models/Service.js b/src/models/Service.js
index c2b081864..4b78b9a40 100644
--- a/src/models/Service.js
+++ b/src/models/Service.js
@@ -14,7 +14,7 @@ const debug = require('debug')('Ferdi:Service');
14export default class Service { 14export default class Service {
15 id = ''; 15 id = '';
16 16
17 recipe = ''; 17 recipe = null;
18 18
19 _webview = null; 19 _webview = null;
20 20
@@ -94,13 +94,11 @@ export default class Service {
94 94
95 constructor(data, recipe) { 95 constructor(data, recipe) {
96 if (!data) { 96 if (!data) {
97 console.error('Service config not valid'); 97 throw Error('Service config not valid');
98 return null;
99 } 98 }
100 99
101 if (!recipe) { 100 if (!recipe) {
102 console.error('Service recipe not valid'); 101 throw Error('Service recipe not valid');
103 return null;
104 } 102 }
105 103
106 this.userAgentModel = new UserAgent(recipe.overrideUserAgent); 104 this.userAgentModel = new UserAgent(recipe.overrideUserAgent);