File tree Expand file tree Collapse file tree 4 files changed +8
-8
lines changed Expand file tree Collapse file tree 4 files changed +8
-8
lines changed Original file line number Diff line number Diff line change @@ -88,11 +88,11 @@ async function run() {
88
88
}
89
89
90
90
process
91
- . on ( 'SIGTERM' , function ( ) {
91
+ . once ( 'SIGTERM' , function ( ) {
92
92
console . log ( "\nTerminating" ) ;
93
93
process . exit ( 0 ) ;
94
94
} )
95
- . on ( 'SIGINT' , function ( ) {
95
+ . once ( 'SIGINT' , function ( ) {
96
96
console . log ( "\nTerminating" ) ;
97
97
process . exit ( 0 ) ;
98
98
} ) ;
Original file line number Diff line number Diff line change @@ -149,11 +149,11 @@ async function runTest() {
149
149
}
150
150
151
151
process
152
- . on ( 'SIGTERM' , function ( ) {
152
+ . once ( 'SIGTERM' , function ( ) {
153
153
console . log ( "\nTerminating" ) ;
154
154
process . exit ( 0 ) ;
155
155
} )
156
- . on ( 'SIGINT' , function ( ) {
156
+ . once ( 'SIGINT' , function ( ) {
157
157
console . log ( "\nTerminating" ) ;
158
158
process . exit ( 0 ) ;
159
159
} ) ;
Original file line number Diff line number Diff line change @@ -149,11 +149,11 @@ async function runTest() {
149
149
}
150
150
151
151
process
152
- . on ( 'SIGTERM' , function ( ) {
152
+ . once ( 'SIGTERM' , function ( ) {
153
153
console . log ( "\nTerminating" ) ;
154
154
process . exit ( 0 ) ;
155
155
} )
156
- . on ( 'SIGINT' , function ( ) {
156
+ . once ( 'SIGINT' , function ( ) {
157
157
console . log ( "\nTerminating" ) ;
158
158
process . exit ( 0 ) ;
159
159
} ) ;
Original file line number Diff line number Diff line change @@ -83,11 +83,11 @@ async function run() {
83
83
}
84
84
85
85
process
86
- . on ( 'SIGTERM' , function ( ) {
86
+ . once ( 'SIGTERM' , function ( ) {
87
87
console . log ( "\nTerminating" ) ;
88
88
process . exit ( 0 ) ;
89
89
} )
90
- . on ( 'SIGINT' , function ( ) {
90
+ . once ( 'SIGINT' , function ( ) {
91
91
console . log ( "\nTerminating" ) ;
92
92
process . exit ( 0 ) ;
93
93
} ) ;
You can’t perform that action at this time.
0 commit comments