fix: chaos in DM session

This commit is contained in:
Tristan Yang
2022-07-01 17:59:49 +08:00
parent b350328206
commit b59e3fd1ac
2 changed files with 3 additions and 1 deletions
@@ -91,6 +91,7 @@ const GoogleLoginInner: FC<Props> = ({ type = "login", loaded, loadError }) => {
const GoogleLoginButton: FC<Props> = ({ type = "login", clientId }) => {
const [scriptLoaded, setScriptLoaded] = useState(false);
const [hasError, setHasError] = useState(false);
if (!clientId) return null;
return (
<GoogleOAuthProvider
onScriptLoadError={() => {
+2 -1
View File
@@ -47,12 +47,13 @@ let inter: number | null = null;
export default function useStreaming() {
const [readyPullData, setReadyPullData] = useState(false);
const {
authData: { uid: loginUid },
authData,
ui: { ready, online },
footprint: { afterMid, usersVersion, readUsers, readChannels }
} = useAppSelector((store) => store);
const [renewToken] = useRenewMutation();
const dispatch = useAppDispatch();
const loginUid = authData.user?.uid;
let initialized = false;
let initializing = false;
let controller = new AbortController();