mirror of
https://github.com/hydralauncher/hydra.git
synced 2026-01-18 08:43:57 +00:00
rename method
This commit is contained in:
2
src/renderer/src/declaration.d.ts
vendored
2
src/renderer/src/declaration.d.ts
vendored
@@ -112,7 +112,7 @@ declare global {
|
||||
restartAndInstallUpdate: () => Promise<void>;
|
||||
|
||||
/* Authg */
|
||||
signout: () => Promise<void>;
|
||||
signOut: () => Promise<void>;
|
||||
onSignIn: (cb: () => void) => () => Electron.IpcRenderer;
|
||||
onSignOut: (cb: () => void) => () => Electron.IpcRenderer;
|
||||
|
||||
|
||||
@@ -5,13 +5,13 @@ import { setUserAuth } from "@renderer/features";
|
||||
export function useUserAuth() {
|
||||
const dispatch = useAppDispatch();
|
||||
|
||||
const [isLoading, setIsLoading] = useState(false);
|
||||
const [isLoading, setIsLoading] = useState(true);
|
||||
|
||||
const { userAuth } = useAppSelector((state) => state.userAuth);
|
||||
|
||||
const signOut = useCallback(async () => {
|
||||
dispatch(setUserAuth(null));
|
||||
return window.electron.signout();
|
||||
return window.electron.signOut();
|
||||
}, [dispatch]);
|
||||
|
||||
const updateUserAuth = useCallback(async () => {
|
||||
|
||||
Reference in New Issue
Block a user