Pārlūkot izejas kodu

kill the fullstack server before starting another one

Evan Almloff 1 gadu atpakaļ
vecāks
revīzija
ab79c00cd8
1 mainītis faili ar 1 papildinājumiem un 0 dzēšanām
  1. 1 0
      packages/cli/src/server/desktop/mod.rs

+ 1 - 0
packages/cli/src/server/desktop/mod.rs

@@ -263,6 +263,7 @@ impl Platform for DesktopPlatform {
     }
 
     fn rebuild(&mut self, config: &CrateConfig) -> Result<BuildResult> {
+        self.currently_running_child.0.kill()?;
         let (child, result) = start_desktop(config, self.skip_assets)?;
         self.currently_running_child = child;
         Ok(result)