Skip to content

Commit 6cbf908

Browse files
committed
TUN-5255: Fix potential panic if Cloudflare API fails to respond to GetTunnel(id) during delete command
1 parent 76ade67 commit 6cbf908

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

cmd/cloudflared/tunnel/subcommand_context.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -230,7 +230,7 @@ func (sc *subcommandContext) delete(tunnelIDs []uuid.UUID) error {
230230
for _, id := range tunnelIDs {
231231
tunnel, err := client.GetTunnel(id)
232232
if err != nil {
233-
return errors.Wrapf(err, "Can't get tunnel information. Please check tunnel id: %s", tunnel.ID)
233+
return errors.Wrapf(err, "Can't get tunnel information. Please check tunnel id: %s", id)
234234
}
235235

236236
// Check if tunnel DeletedAt field has already been set

0 commit comments

Comments
 (0)