Skip to content

Commit

Permalink
for better cache hit
Browse files Browse the repository at this point in the history
  • Loading branch information
ap-justin committed Dec 21, 2023
1 parent 38a3266 commit 92f2b94
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 11 deletions.
2 changes: 1 addition & 1 deletion src/App/Header/UserMenu/EndowmentLink.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import { appRoutes } from "constants/routes";

type Props = { endowId: number };
export default function EndowmentLink({ endowId }: Props) {
const query = useEndowment(endowId, ["name", "logo"]);
const query = useEndowment(endowId, ["logo", "name"]);
return (
<QueryLoader
queryState={query}
Expand Down
7 changes: 1 addition & 6 deletions src/pages/Admin/Charity/Seo.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,7 @@ export default function Seo({
url?: string;
}) {
const { id } = useAdminContext();
const { data: profile } = useEndowment(id, [
"name",
"overview",
"name",
"logo",
]);
const { data: profile } = useEndowment(id, ["logo", "name", "overview"]);

return (
<CommonSEO
Expand Down
8 changes: 4 additions & 4 deletions src/pages/Donate/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,13 @@ export default function Donate() {
const { id } = useParams<{ id: string }>();
const numId = idParamToNum(id);
const queryState = useEndowment(numId, [
"name",
"fiscal_sponsored",
"id",
"image",
"kyc_donors_only",
"logo",
"name",
"overview",
"kyc_donors_only",
"fiscal_sponsored",
"id",
]);

return (
Expand Down

0 comments on commit 92f2b94

Please sign in to comment.