Skip to content
This repository has been archived by the owner on Oct 4, 2024. It is now read-only.

Commit

Permalink
fix: create-account
Browse files Browse the repository at this point in the history
  • Loading branch information
gagdiez committed Mar 4, 2024
1 parent e570a2d commit 6b6fd8d
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions commands/account/create.js
Original file line number Diff line number Diff line change
Expand Up @@ -80,9 +80,9 @@ async function assertAccountDoesNotExist(accountId, near) {
await account.state();
throw new Error(`Sorry, account '${accountId}' already exists.`);
} catch (e) {
if (!e.message.includes('does not exist while viewing')) {
throw e;
}
const opt1 = e.message.includes('does not exist');
const opt2 = e.message.includes('doesn\'t exist');
if (!opt1 && !opt2) throw e;
}
}

Expand Down

0 comments on commit 6b6fd8d

Please sign in to comment.