diff options
author | Aleš Smodiš <aless@guru.si> | 2015-10-01 19:17:45 +0200 |
---|---|---|
committer | Aleš Smodiš <aless@guru.si> | 2015-10-01 19:17:45 +0200 |
commit | 1097b8392f799caa0e28334b67293b893beb5910 (patch) | |
tree | 97f5e6636f843d2fbcbbe6ff9f31ca8c50fed28d /js/codeq | |
parent | 7d0efb9985656d7f5a51671cc1bfda7417d133ee (diff) |
Bugfix core.js: fallback JSONization function, resource resolving function.
Diffstat (limited to 'js/codeq')
-rw-r--r-- | js/codeq/core.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/js/codeq/core.js b/js/codeq/core.js index 4b03bfb..6b0719b 100644 --- a/js/codeq/core.js +++ b/js/codeq/core.js @@ -5,7 +5,7 @@ // JSON-ization (stringification) function // ================================================================================ - var jsonize = JSON && JSON.stringify || function () { + var jsonize = JSON && JSON.stringify || function (obj) { var t, buffer, i, isFirst; if (null === obj) return 'null'; t = typeof obj; @@ -38,6 +38,7 @@ buffer = [ '{' ]; isFirst = true; for (i in obj) { + if (!obj.hasOwnProperty(i)) continue; if (isFirst) isFirst = false; else buffer.push(','); buffer.push(jsonize(i), ':', jsonize(obj[i])); @@ -296,7 +297,6 @@ branch = branch[fragment]; if (!branch) { codeq.log.error('Resource sub-branch ' + fragment + ' does not exist; resource: "' + resourceName + '", path: "' + templatePath.join('/') + '"'); - code.push('_result.push("data/broken.png");\n'); break; } traversedPath.push(fragment); |