Skip to content

Commit 3370f55

Browse files
feat: improve restart message
1 parent 12dc645 commit 3370f55

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/mcpm/commands/router.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -180,6 +180,7 @@ def set_router_config(host, port):
180180
console.print(" mcpm router on")
181181
else:
182182
console.print("[bold red]Error:[/] Failed to save router configuration.")
183+
return
183184

184185
if Confirm.ask("Do you want to update router for all clients now?"):
185186
active_profile = ClientRegistry.get_active_profile()
@@ -200,7 +201,8 @@ def set_router_config(host, port):
200201
client_manager.activate_profile(active_profile, config_manager.get_router_config())
201202
console.print(f"[green]Profile router updated for {client}[/]")
202203
console.print("[bold green]Success: Profile router updated for all clients[/]")
203-
console.print("[bold yellow]Restart MCPRouter to apply new settings.[/]\n")
204+
if pid:
205+
console.print("[bold yellow]Restart MCPRouter to apply new settings.[/]\n")
204206

205207

206208
@router.command(name="off")

0 commit comments

Comments
 (0)