Skip to content
This repository has been archived by the owner on Jul 16, 2023. It is now read-only.

Commit

Permalink
fix: improve rejection when boogi is already initialized in current dir
Browse files Browse the repository at this point in the history
  • Loading branch information
filipowm committed Oct 27, 2020
1 parent b22a691 commit 6576a1b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/commands/init/init.js
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ exports.builder = (yargs) => {
const verifyBoogiApp = (ctx) => {
return new Promise((resolve, reject) => {
if (isBoogiApp(ctx.path)) {
reject("BooGi was already initialized!");
reject(new Error("BooGi was already initialized!"));
} else {
resolve();
}
Expand Down Expand Up @@ -128,7 +128,7 @@ exports.handler = async function (argv) {
],
{ ...argv, gitInfo: gitInfo, path: path }
).then((ctx) => {
if (typeof ctx === 'string') {
if (typeof ctx !== "object") {
return false;
}
getVersion(ctx).collect((result) => {
Expand Down

0 comments on commit 6576a1b

Please sign in to comment.