From bb05f96ff5811178ecf430f3a2f34946a45cf9e3 Mon Sep 17 00:00:00 2001 From: Konstantin Wohlwend Date: Thu, 19 Dec 2024 11:19:41 -0800 Subject: [PATCH] Fix types --- apps/dashboard/src/components/data-table/user-table.tsx | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/apps/dashboard/src/components/data-table/user-table.tsx b/apps/dashboard/src/components/data-table/user-table.tsx index e4d84e003..77cb7f947 100644 --- a/apps/dashboard/src/components/data-table/user-table.tsx +++ b/apps/dashboard/src/components/data-table/user-table.tsx @@ -171,7 +171,9 @@ const columns: ColumnDef[] = [ }, ]; -export function extendUsers(users: ServerUser[] & { nextCursor: string | null }): ExtendedServerUser[] & { nextCursor: string | null } { +export function extendUsers(users: ServerUser[] & { nextCursor: string | null }): ExtendedServerUser[] & { nextCursor: string | null }; +export function extendUsers(users: ServerUser[]): ExtendedServerUser[]; +export function extendUsers(users: ServerUser[] & { nextCursor?: string | null }): ExtendedServerUser[] & { nextCursor: string | null | undefined } { const extended = users.map((user) => ({ ...user, authTypes: [ @@ -210,7 +212,6 @@ export function UserTable() { newFilters.desc = options.sorting[0].desc; } - console.log("AAAAAAAAA", newFilters, filters, deepPlainEquals(newFilters, filters, { ignoreUndefinedValues: true })); if (deepPlainEquals(newFilters, filters, { ignoreUndefinedValues: true })) { // save ourselves a request if the filters didn't change return { nextCursor: users.nextCursor };