mirror of
https://github.com/kovidgoyal/kitty.git
synced 2026-08-27 03:42:49 +00:00
Ensure we are not using iterators when closing
This commit is contained in:
parent
03abbb315a
commit
0c7b4df6fc
2 changed files with 2 additions and 2 deletions
|
|
@ -54,7 +54,7 @@ Do not return an error if no tabs are matched to be closed.
|
|||
if payload_get('ignore_no_match'):
|
||||
return None
|
||||
raise
|
||||
for tab in tabs:
|
||||
for tab in tuple(tabs):
|
||||
if tab:
|
||||
boss.close_tab_no_confirm(tab)
|
||||
return None
|
||||
|
|
|
|||
|
|
@ -46,7 +46,7 @@ Do not return an error if no windows are matched to be closed.
|
|||
if payload_get('ignore_no_match'):
|
||||
return None
|
||||
raise
|
||||
for window in windows:
|
||||
for window in tuple(windows):
|
||||
if window:
|
||||
boss.mark_window_for_close(window)
|
||||
return None
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue