Skip to content

Commit

Permalink
chore(frontend): adapt to new gql schema
Browse files Browse the repository at this point in the history
  • Loading branch information
IgnisDa committed Jan 6, 2025
1 parent 3b9db90 commit f76fcca
Showing 1 changed file with 9 additions and 10 deletions.
19 changes: 9 additions & 10 deletions apps/frontend/app/routes/_dashboard._index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,10 @@ import {
DashboardElementLot,
GraphqlSortOrder,
MediaLot,
RefreshUserRecommendationsKeyDocument,
RefreshUserMetadataRecommendationsKeyDocument,
UserAnalyticsDocument,
UserMetadataRecommendationsDocument,
type UserPreferences,
UserRecommendationsDocument,
UserUpcomingCalendarEventsDocument,
} from "@ryot/generated/graphql/backend/graphql";
import {
Expand Down Expand Up @@ -96,12 +96,12 @@ export const loader = async ({ request }: LoaderFunctionArgs) => {
)?.hidden
)
return [];
const { userRecommendations } = await serverGqlService.authenticatedRequest(
request,
UserRecommendationsDocument,
{},
);
return userRecommendations;
const { userMetadataRecommendations } =
await serverGqlService.authenticatedRequest(
request,
UserMetadataRecommendationsDocument,
);
return userMetadataRecommendations;
};
const userCollectionsList = await getUserCollectionsList(request);
const foundInProgressCollection = userCollectionsList.find(
Expand Down Expand Up @@ -152,8 +152,7 @@ export const action = async ({ request }: ActionFunctionArgs) => {
.with("refreshUserRecommendationsKey", async () => {
await serverGqlService.authenticatedRequest(
request,
RefreshUserRecommendationsKeyDocument,
{},
RefreshUserMetadataRecommendationsKeyDocument,
);
return {};
})
Expand Down

0 comments on commit f76fcca

Please sign in to comment.