Rewrite AppDomain to handle uncaughts & promises

This commit is contained in:
2022-04-06 13:51:04 +09:00
parent 7dedaf8d77
commit 5674f3936c
9 changed files with 137 additions and 91 deletions
+10
View File
@@ -30,6 +30,16 @@ class CResponse
this.raw.writeHead( this.statusCode, this.headers );
this.raw.end( this.content );
if( this.raw._rejection )
{
process.removeListener( "unhandledRejection", this.raw._rejection );
}
if( this.raw._uncaught )
{
process.removeListener( "uncaughtException", this.raw._uncaught );
}
}
}