devops: fix next version generation

This commit is contained in:
Andrey Lushnikov 2020-04-20 17:53:08 -07:00
parent ac8a30c526
commit 068e1e00af

View File

@ -47,7 +47,7 @@ if (version === '--next') {
const packageJSON = require('../package.json');
version = packageJSON.version;
const dashIndex = version.indexOf('-');
if (dashIndex === -1)
if (dashIndex !== -1)
version = version.substring(0, dashIndex);
version += '-next.' + Date.now();
console.log('Setting version to ' + version);