Skip to content

Commit

Permalink
fix(apps/gql): add site arg to post.bySite loader connection key (#626)
Browse files Browse the repository at this point in the history
# Description

Fixes getting error from postBySite query 😃
  • Loading branch information
rasitds authored Aug 10, 2023
1 parent 15a5c5c commit d8139ff
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion apps/gql/schema/resolvers/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ export const resolvers = {
},
postsBySite: async (_, args, { loaders }) => {
const posts = await loaders.pano.post.bySite.load(
new ConnectionKey(null, parseConnectionArgs(args), { orderBy: { createdAt: "desc" } })
new ConnectionKey(args.site, parseConnectionArgs(args), { orderBy: { createdAt: "desc" } })
);

return transformPanoPostConnection(posts);
Expand Down

0 comments on commit d8139ff

Please sign in to comment.