mirror of
https://github.com/mathuo/dockview
synced 2025-08-14 21:26:01 +00:00
check tabToRemove is not undefined before access
This commit is contained in:
parent
ca09ae537d
commit
3e409c4265
@ -283,6 +283,9 @@ export class TabsContainer
|
||||
|
||||
const tabToRemove = this.tabs.splice(index, 1)[0];
|
||||
|
||||
if (!tabToRemove)
|
||||
return;
|
||||
|
||||
const { value, disposable } = tabToRemove;
|
||||
|
||||
disposable.dispose();
|
||||
|
Loading…
x
Reference in New Issue
Block a user