]> source.dussan.org Git - nextcloud-server.git/commitdiff
Fix default value of operator
authorJoas Schilling <coding@schilljs.com>
Wed, 27 Jul 2016 10:29:30 +0000 (12:29 +0200)
committerJoas Schilling <coding@schilljs.com>
Wed, 27 Jul 2016 10:29:30 +0000 (12:29 +0200)
apps/workflowengine/js/admin.js

index 394c580fbb505848877dda9571395c93e8fed2e1..48d1592b4571a0b2a4c77da46a87c0ff65bab365 100644 (file)
 
                                checks.push({
                                        'class': classname,
-                                       'operator': operators[0],
+                                       'operator': operators[0]['operator'],
                                        'value': ''
                                });
                                this.model.set({'checks': checks});
                                if (key === 'class') {
                                        var check = OCA.WorkflowEngine.getCheckByClass(value);
                                        if (!_.isUndefined(check)) {
-                                               checks[id]['operator'] = check['operators'][0];
+                                               checks[id]['operator'] = check['operators'][0]['operator'];
                                        }
                                }
                                // model change will trigger render