This commit is contained in:
Vanessa 2023-03-29 19:06:07 +08:00 committed by Liang Ding
parent d5b5c082fb
commit 37f859221a
No known key found for this signature in database
GPG Key ID: 136F30F901A2231D

View File

@ -1,7 +1,8 @@
import {hideMessage, showMessage} from "../dialog/message";
/// #if !MOBILE /// #if !MOBILE
import {exportLayout} from "../layout/util"; import {exportLayout} from "../layout/util";
/// #endif /// #endif
import {isWindow} from "./functions";
import {hideMessage, showMessage} from "../dialog/message";
export const processMessage = (response: IWebSocketData) => { export const processMessage = (response: IWebSocketData) => {
if ("msg" === response.cmd) { if ("msg" === response.cmd) {
@ -23,7 +24,11 @@ export const processMessage = (response: IWebSocketData) => {
/// #if MOBILE /// #if MOBILE
window.location.reload(); window.location.reload();
/// #else /// #else
exportLayout(true); if (isWindow()) {
window.location.reload();
} else {
exportLayout(true);
}
/// #endif /// #endif
return false; return false;
} }