From 096ac9b15905f3e0eb7f42e9f1e05b75a0f4e7ad Mon Sep 17 00:00:00 2001 From: David Jones Date: Fri, 30 Jun 2017 14:29:42 -0700 Subject: [PATCH] return unknown if we can't extract the version number of ember and ember-cli --- index.js | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/index.js b/index.js index 96a308b0..527c0601 100644 --- a/index.js +++ b/index.js @@ -128,9 +128,7 @@ module.exports = { this._environmentInfoCache = [ `ember/${this._emberSourceVersion()}`, `ember-cli/${this._emberCliVersion()}` - ].filter(function(el) { - return !el.match(/\/$/); - }).join('; '); + ].join('; '); } return this._environmentInfoCache; @@ -140,7 +138,7 @@ module.exports = { try { return require('ember-source/package.json').version; } catch (e) { - return ''; + return 'unknown'; }; }, @@ -148,7 +146,7 @@ module.exports = { try { return require('ember-cli/lib/utilities/version-utils').emberCLIVersion(); } catch (e) { - return ''; + return 'unknown'; }; },