From 19b889e64529e54006d43e6a503db6ff21ec219b Mon Sep 17 00:00:00 2001 From: yann300 Date: Fri, 27 Jul 2018 10:44:59 +0200 Subject: [PATCH] resolve only networkname if id no present --- src/app/files/compiler-metadata.js | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/app/files/compiler-metadata.js b/src/app/files/compiler-metadata.js index 2eedb2ca31..406ad9e2e2 100644 --- a/src/app/files/compiler-metadata.js +++ b/src/app/files/compiler-metadata.js @@ -73,9 +73,7 @@ class CompilerMetadata { if (error) return callback(error) try { var metadata = JSON.parse(content) - if (metadata[name + ':' + id]) { - callback(null, metadata[name + ':' + id]) - } + return callback(null, metadata[name + ':' + id] || metadata[name]) } catch (e) { callback(e.message) }