From a7e3400e42d6de97224d6eb41e05ddc1080c5727 Mon Sep 17 00:00:00 2001 From: Jake Fried Date: Mon, 28 Dec 2020 09:50:48 -0500 Subject: [PATCH] Update error msg + missing await --- source/git-util.js | 2 +- source/index.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/source/git-util.js b/source/git-util.js index b87074e3..d65669ca 100644 --- a/source/git-util.js +++ b/source/git-util.js @@ -174,7 +174,7 @@ exports.defaultBranch = async () => { } throw new Error( - 'Could not infer the default Git branch. Please specify one with the --branch flag or with an .np-config file.' + 'Could not infer the default Git branch. Please specify one with the --branch flag or with a np config.' ); }; diff --git a/source/index.js b/source/index.js index aa4364b1..36ed24f4 100644 --- a/source/index.js +++ b/source/index.js @@ -47,7 +47,7 @@ module.exports = async (input = 'patch', options) => { options.cleanup = false; } - options.releaseBranch = options.releaseBranch || git.defaultBranch(); + options.releaseBranch = options.releaseBranch || await git.defaultBranch(); const pkg = util.readPkg(options.contents); const runTests = options.tests && !options.yolo;