Skip to content

Commit

Permalink
Expands organization property on getMe response
Browse files Browse the repository at this point in the history
  • Loading branch information
allanlasser committed Apr 3, 2024
1 parent 793f1d0 commit 0b311f9
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/lib/api/accounts.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ type Fetch = typeof globalThis.fetch;
/** Get the logged-in user */
export async function getMe(fetch: Fetch): Promise<Maybe<User>> {
const endpoint = new URL("users/me/", BASE_API_URL);
endpoint.searchParams.set("expand", "organization");
try {
const resp = await fetch(endpoint, { credentials: "include" });
if (!resp.ok) return;
Expand Down

0 comments on commit 0b311f9

Please sign in to comment.