fix: only check initableServerComponents for init server check (#1725)
Signed-off-by: Stefan Dej <meteyou@gmail.com>
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
import { Store } from 'vuex'
|
||||
import _Vue from 'vue'
|
||||
import { RootState } from '@/store/types'
|
||||
import { initableServerComponents } from '@/store/variables'
|
||||
|
||||
export class WebSocketClient {
|
||||
url = ''
|
||||
@@ -67,7 +68,13 @@ export class WebSocketClient {
|
||||
}
|
||||
|
||||
if (wait?.id) {
|
||||
if (wait.action?.startsWith('server/')) {
|
||||
const modulename = wait.action?.split('/')[1] ?? null
|
||||
|
||||
if (
|
||||
modulename &&
|
||||
wait.action?.startsWith('server/') &&
|
||||
initableServerComponents.includes(modulename)
|
||||
) {
|
||||
const component = wait.action.replace('server/', '').split('/')[0]
|
||||
window.console.error(`init server component ${component} failed`)
|
||||
this.store?.dispatch('server/addFailedInitComponent', component)
|
||||
|
Reference in New Issue
Block a user