mirror of
https://github.com/wavetermdev/waveterm.git
synced 2025-01-21 21:32:13 +01:00
Fix nullchecks in wave.ts (#1491)
This commit is contained in:
parent
7ecdf249bd
commit
448262c17f
@ -112,10 +112,10 @@ function reloadAllWorkspaceTabs(ws: Workspace) {
|
||||
if (ws == null || (!ws.tabids?.length && !ws.pinnedtabids?.length)) {
|
||||
return;
|
||||
}
|
||||
ws?.tabids.forEach((tabid) => {
|
||||
ws.tabids?.forEach((tabid) => {
|
||||
WOS.reloadWaveObject<Tab>(WOS.makeORef("tab", tabid));
|
||||
});
|
||||
ws?.pinnedtabids?.forEach((tabid) => {
|
||||
ws.pinnedtabids?.forEach((tabid) => {
|
||||
WOS.reloadWaveObject<Tab>(WOS.makeORef("tab", tabid));
|
||||
});
|
||||
}
|
||||
@ -124,10 +124,10 @@ function loadAllWorkspaceTabs(ws: Workspace) {
|
||||
if (ws == null || (!ws.tabids?.length && !ws.pinnedtabids?.length)) {
|
||||
return;
|
||||
}
|
||||
ws.tabids.forEach((tabid) => {
|
||||
ws.tabids?.forEach((tabid) => {
|
||||
WOS.getObjectValue<Tab>(WOS.makeORef("tab", tabid));
|
||||
});
|
||||
ws.pinnedtabids.forEach((tabid) => {
|
||||
ws.pinnedtabids?.forEach((tabid) => {
|
||||
WOS.getObjectValue<Tab>(WOS.makeORef("tab", tabid));
|
||||
});
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user