Merge pull request #9 from OstlerDev/handle-sigint
Handle SIGINT close signal
This commit is contained in:
commit
cf52e9575e
4
bin/node
4
bin/node
@ -45,6 +45,10 @@ process.on('unhandledRejection', (err, promise) => {
|
||||
throw err;
|
||||
});
|
||||
|
||||
process.on('SIGINT', async () => {
|
||||
await node.close();
|
||||
});
|
||||
|
||||
(async () => {
|
||||
await node.ensure();
|
||||
await node.open();
|
||||
|
||||
@ -33,6 +33,10 @@ process.on('unhandledRejection', (err, promise) => {
|
||||
throw err;
|
||||
});
|
||||
|
||||
process.on('SIGINT', async () => {
|
||||
await node.close();
|
||||
});
|
||||
|
||||
(async () => {
|
||||
await node.ensure();
|
||||
await node.open();
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "fcoin",
|
||||
"version": "1.0.1",
|
||||
"version": "1.0.2",
|
||||
"description": "Flo bike-shed",
|
||||
"license": "MIT",
|
||||
"repository": "git://github.com/oipwg/fcoin.git",
|
||||
|
||||
Loading…
Reference in New Issue
Block a user