Skip to content

Commit

Permalink
fix: reject promise with an error
Browse files Browse the repository at this point in the history
  • Loading branch information
egoist committed Apr 2, 2022
1 parent 11d9be1 commit 401e204
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/index.ts
Expand Up @@ -162,7 +162,7 @@ export async function build(_options: Options) {
worker.on('message', (data) => {
if (data === 'error') {
process.exitCode = 1
reject()
reject(new Error('Failed to bundle declaration files'))
} else if (data === 'success') {
process.exitCode = 0
resolve()
Expand Down

0 comments on commit 401e204

Please sign in to comment.