From 4c3365b5a6e4f2b696699b20ee099f3376d00df4 Mon Sep 17 00:00:00 2001 From: Connor Peet Date: Tue, 12 Jun 2018 11:13:42 -0700 Subject: [PATCH] fix(controls): don't orphan webpack process when webpack config is changed (fixes #115) --- src/app/editor/controls/control.effects.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/app/editor/controls/control.effects.ts b/src/app/editor/controls/control.effects.ts index a9a3f7f..6ad87f3 100644 --- a/src/app/editor/controls/control.effects.ts +++ b/src/app/editor/controls/control.effects.ts @@ -30,6 +30,7 @@ import { isRunning, IWebpackInstance, PromptLocateWebpackConfig, + RestartWebpack, SendControlPacket, SetWebpackInstance, StartWebpack, @@ -230,7 +231,7 @@ export class ControlEffects { switchMap(([, directory]) => this.electron .call(ControlsMethods.SetWebpackConfig, { directory }) - .then(path => (path ? new StartWebpack() : null)), + .then(path => (path ? new RestartWebpack() : null)), ), truthy(), );