Skip to content

Commit

Permalink
reset sigint on stop
Browse files Browse the repository at this point in the history
  • Loading branch information
AndiDittrich committed May 17, 2022
1 parent 33ef015 commit f5aeca3
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions lib/multi-bar.js
Original file line number Diff line number Diff line change
Expand Up @@ -178,6 +178,7 @@ module.exports = class MultiBar extends _EventEmitter{
if (this.sigintCallback){
process.removeListener('SIGINT', this.sigintCallback);
process.removeListener('SIGTERM', this.sigintCallback);
this.sigintCallback = null;
}

// set flag
Expand Down
1 change: 1 addition & 0 deletions lib/single-bar.js
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,7 @@ module.exports = class SingleBar extends _GenericBar{
if (this.sigintCallback){
process.removeListener('SIGINT', this.sigintCallback);
process.removeListener('SIGTERM', this.sigintCallback);
this.sigintCallback = null;
}

// trigger final rendering
Expand Down

0 comments on commit f5aeca3

Please sign in to comment.