Infinite Call Using Organizations

Hey there, so I'm trying to get this to work, but when I open my app it keeps fetching the following endpoint on and on.
GET /api/auth/organization/list 200 in 45ms

I'm using it like this:
const authClient = createAuthClient({
baseURL: getBaseUrl(),
plugins: [
organizationClient({
teams: {
enabled: true
}
}),
]
});
const { data } = authClient.useListOrganizations();
console.log(data)

this is my auth.ts file
import { betterAuth } from "better-auth";
import { nextCookies } from "better-auth/next-js";
import { drizzleAdapter } from "better-auth/adapters/drizzle";
import { organization } from "better-auth/plugins"
import { db } from "@ideate/server/db";

export const auth = betterAuth({
plugins: [
organization({
teams: {
enabled: true,
maximumTeams: 10,
allowRemovingAllTeams: true,
}
}),
nextCookies()
],
database: drizzleAdapter(db, {
provider: "pg",
}),
});

Am I missing something?
Was this page helpful?