Lutz Roeder преди 1 месец
родител
ревизия
180786e256
променени са 1 файла, в които са добавени 1 реда и са изтрити 1 реда
  1. 1 1
      source/message.js

+ 1 - 1
source/message.js

@@ -109,7 +109,7 @@ message.Argument = class {
 message.Value = class {
 
     constructor(data) {
-        this.name = data.name ? data.name.toString() : '';
+        this.name = data.name !== undefined && data.name !== null ? data.name.toString() : '';
         this.initializer = data.initializer ? new message.Tensor(data.initializer) : null;
         if (this.initializer && this.initializer.type) {
             this.type = this.initializer.type;