You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// Check if tunnel DeletedAt field has already been set
346
+
if!tunnel.DeletedAt.IsZero() {
347
+
returnerrors.New("This tunnel has already been deleted.")
348
+
}
349
+
// Check if tunnel has existing connections and if force flag is set, cleanup connections
350
+
iflen(tunnel.Connections) >0 {
351
+
if!forceFlagSet {
352
+
returnerrors.New("You can not delete this tunnel because it has active connections. To see connections run the 'list' command. If you believe the tunnel is not active, you can use a -f / --force flag with this command.")
353
+
}
354
+
355
+
iferr:=client.CleanupConnections(id); err!=nil {
356
+
returnerrors.Wrapf(err, "Error cleaning up connections for tunnel %s", id)
0 commit comments