fix: handle undefined desktop service when running in web environment
This commit is contained in:
@@ -77,9 +77,14 @@ export class WebApplication extends SNApplication {
|
|||||||
}
|
}
|
||||||
|
|
||||||
for (const service of Object.values(this.webServices)) {
|
for (const service of Object.values(this.webServices)) {
|
||||||
|
if (!service) {
|
||||||
|
continue
|
||||||
|
}
|
||||||
|
|
||||||
if ('deinit' in service) {
|
if ('deinit' in service) {
|
||||||
service.deinit?.(source)
|
service.deinit?.(source)
|
||||||
}
|
}
|
||||||
|
|
||||||
;(service as { application?: WebApplication }).application = undefined
|
;(service as { application?: WebApplication }).application = undefined
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user