Ensure errors in node def funcs don't break view rendering

Fixes #815

 - also fixes errors in the Catch/Status node label funcs #815
This commit is contained in:
Nick O'Leary
2016-03-01 21:58:57 +00:00
parent 2e2556fdad
commit 0e2d13172a
4 changed files with 71 additions and 25 deletions

View File

@@ -1,5 +1,5 @@
<!--
Copyright 2015 IBM Corp.
Copyright 2015, 2016 IBM Corp.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
@@ -106,7 +106,7 @@
outputs:1,
icon: "alert.png",
label: function() {
return this.name||this.scope?this._("catch.catchNodes",{number:this.scope.length}):this._("catch.catch");
return this.name||(this.scope?this._("catch.catchNodes",{number:this.scope.length}):this._("catch.catch"));
},
labelStyle: function() {
return this.name?"node_label_italic":"";

View File

@@ -1,5 +1,5 @@
<!--
Copyright 2015 IBM Corp.
Copyright 2015, 2016 IBM Corp.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
@@ -97,7 +97,7 @@
outputs:1,
icon: "alert.png",
label: function() {
return this.name||this.scope?this._("status.statusNodes",{number:this.scope.length}):this._("status.status");
return this.name||(this.scope?this._("status.statusNodes",{number:this.scope.length}):this._("status.status"));
},
labelStyle: function() {
return this.name?"node_label_italic":"";