mirror of
https://github.com/ChatGPTNextWeb/ChatGPT-Next-Web.git
synced 2025-10-01 23:56:39 +08:00
fix
This commit is contained in:
parent
f123ffc74b
commit
7fac17f189
@ -28,6 +28,7 @@ import { useAppConfig } from "../store/config";
|
|||||||
import { AuthPage } from "./auth";
|
import { AuthPage } from "./auth";
|
||||||
import { getClientConfig } from "../config/client";
|
import { getClientConfig } from "../config/client";
|
||||||
import { type ClientApi, getClientApi } from "../client/api";
|
import { type ClientApi, getClientApi } from "../client/api";
|
||||||
|
import { useAccessStore } from "../store";
|
||||||
import { useSyncStore } from "../store/sync";
|
import { useSyncStore } from "../store/sync";
|
||||||
import { showToast } from "./ui-lib";
|
import { showToast } from "./ui-lib";
|
||||||
import Locale from "@/app/locales";
|
import Locale from "@/app/locales";
|
||||||
@ -159,7 +160,6 @@ function useSyncOnStart() {
|
|||||||
if (!(running && syncStore.cloudSync() && syncStore.autoSync.onStart)) {
|
if (!(running && syncStore.cloudSync() && syncStore.autoSync.onStart)) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
console.debug("wtf", syncStore.autoSync, syncStore.cloudSync());
|
|
||||||
const dismissSyncingToast = showToast(Locale.Settings.Sync.IsSyncing);
|
const dismissSyncingToast = showToast(Locale.Settings.Sync.IsSyncing);
|
||||||
try {
|
try {
|
||||||
await syncStore.sync();
|
await syncStore.sync();
|
||||||
@ -254,8 +254,10 @@ export function Home() {
|
|||||||
useSwitchTheme();
|
useSwitchTheme();
|
||||||
useLoadData();
|
useLoadData();
|
||||||
useHtmlLang();
|
useHtmlLang();
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
console.log("[Config] got config from build time", getClientConfig());
|
console.log("[Config] got config from build time", getClientConfig());
|
||||||
|
useAccessStore.getState().fetch();
|
||||||
}, []);
|
}, []);
|
||||||
|
|
||||||
if (!useHasHydrated()) {
|
if (!useHasHydrated()) {
|
||||||
|
Loading…
Reference in New Issue
Block a user