removed auth from data step

This commit is contained in:
Oleg Yakovenko 2024-08-07 13:09:29 +03:00
parent 939de83654
commit b03533dea6
1 changed files with 0 additions and 6 deletions

View File

@ -12,7 +12,6 @@ import { CoverButton } from "~/pages/root/steps/data-step/components/cover-butto
import { HiddenFileInput } from "~/shared/ui/hidden-file-input"; import { HiddenFileInput } from "~/shared/ui/hidden-file-input";
import { useRootStore } from "~/shared/stores/root"; import { useRootStore } from "~/shared/stores/root";
import { Checkbox } from "~/shared/ui/checkbox"; import { Checkbox } from "~/shared/ui/checkbox";
import { useAuth } from "~/shared/services/auth";
type DataStepProps = { type DataStepProps = {
nextStep(): void; nextStep(): void;
@ -20,7 +19,6 @@ type DataStepProps = {
export const DataStep = ({ nextStep }: DataStepProps) => { export const DataStep = ({ nextStep }: DataStepProps) => {
const rootStore = useRootStore(); const rootStore = useRootStore();
const auth = useAuth();
const formSchema = useMemo(() => { const formSchema = useMemo(() => {
return z.object({ return z.object({
@ -49,10 +47,6 @@ export const DataStep = ({ nextStep }: DataStepProps) => {
if (values.author) { if (values.author) {
rootStore.setAuthor(values.author); rootStore.setAuthor(values.author);
} }
const res = await auth.mutateAsync();
sessionStorage.setItem("auth_v1_token", res.data.auth_v1_token);
nextStep(); nextStep();
} catch (error) { } catch (error) {
console.error("Error:", error); console.error("Error:", error);