mirror of
https://github.com/kevin-DL/sapper.git
synced 2026-01-12 11:15:14 +00:00
change fatal events to be clonable, for IPC purposes
This commit is contained in:
@@ -90,7 +90,7 @@ class Watcher extends EventEmitter {
|
||||
if (this.port) {
|
||||
if (!await ports.check(this.port)) {
|
||||
this.emit('fatal', <events.FatalEvent>{
|
||||
error: new Error(`Port ${this.port} is unavailable`)
|
||||
message: `Port ${this.port} is unavailable`
|
||||
});
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -7,11 +7,11 @@ export type ReadyEvent = {
|
||||
|
||||
export type ErrorEvent = {
|
||||
type: string;
|
||||
error: Error;
|
||||
message: string;
|
||||
};
|
||||
|
||||
export type FatalEvent = {
|
||||
error: Error;
|
||||
message: string;
|
||||
};
|
||||
|
||||
export type InvalidEvent = {
|
||||
|
||||
Reference in New Issue
Block a user