Skip to content

Commit 7d72722

Browse files
committed
Fix execution order
1 parent 2942c86 commit 7d72722

1 file changed

Lines changed: 6 additions & 8 deletions

File tree

resources/external_control.urscript

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -882,15 +882,11 @@ while not (traj_flag and com_flag and rev_flag):
882882
end
883883

884884
if not (traj_flag and com_flag and rev_flag):
885-
popup(
886-
str_cat(
887-
str_cat("Trajectory socket ({{TRAJECTORY_SERVER_PORT_REPLACE}}) connected: ", traj_flag),
888-
str_cat(
889-
str_cat("<br/>Script command socket ({{SCRIPT_COMMAND_SERVER_PORT_REPLACE}}) connected: ", com_flag),
890-
str_cat(
885+
error_str = str_cat(
886+
str_cat("Trajectory socket ({{TRAJECTORY_SERVER_PORT_REPLACE}}) connected: ", traj_flag), str_cat(
887+
str_cat("<br/>Script command socket ({{SCRIPT_COMMAND_SERVER_PORT_REPLACE}}) connected: ", com_flag), str_cat(
891888
str_cat("<br/>Reverse socket ({{SERVER_PORT_REPLACE}}) connected: ", rev_flag),
892-
"<br/><br/>Please check that the external control end at {{SERVER_IP_REPLACE}} is running correctly. Press 'Continue' to retry."))),
893-
title="Error connecting to remote", blocking=True, error=True)
889+
"<br/><br/>Please check that the external control end at {{SERVER_IP_REPLACE}} is running correctly. Press 'Continue' to retry.")))
894890

895891
if traj_flag:
896892
socket_close("trajectory_socket")
@@ -901,6 +897,8 @@ while not (traj_flag and com_flag and rev_flag):
901897
socket_close("script_command_socket")
902898
com_flag = False
903899
end
900+
901+
popup(error_str, title="Error connecting to remote", blocking=True, error=True)
904902
end
905903
end
906904

0 commit comments

Comments
 (0)