Revert "undo commit"

This reverts commit 9103f67db5.
This commit is contained in:
daniel31x13
2024-11-03 03:27:52 -05:00
parent e37702aa14
commit dbd096ab76
176 changed files with 2362 additions and 9401 deletions
+4 -3
View File
@@ -1,3 +1,4 @@
import { LinkIncludingShortenedCollectionAndTags } from "@/types/global";
import { useQuery } from "@tanstack/react-query";
import { useSession } from "next-auth/react";
@@ -6,11 +7,11 @@ const useDashboardData = () => {
return useQuery({
queryKey: ["dashboardData"],
queryFn: async () => {
const response = await fetch("/api/v2/dashboard");
queryFn: async (): Promise<LinkIncludingShortenedCollectionAndTags[]> => {
const response = await fetch("/api/v1/dashboard");
const data = await response.json();
return data.data;
return data.response;
},
enabled: status === "authenticated",
});