refactor: fix pagination with stable resolveKey, use reactive default… (#4951)
* refactor: fix pagination with stable resolveKey, use reactive defaultRoles, and remove email permission check * Changes from call * More changes from call * WIP fixing team composite cursor * paginated items fix * minor rename * composite cursor tools improved * fe undoing debugging stuff * extra fixes * invitable collabs fix --------- Co-authored-by: Kristaps Fabians Geikins <fabis94@live.com>
This commit is contained in:
committed by
GitHub
parent
794bd7c7e9
commit
c89fe339ec
@@ -133,7 +133,7 @@ const { FF_WORKSPACES_MODULE_ENABLED } = getFeatureFlags()
|
||||
getWorkspaceWithDomains: async () => null,
|
||||
getUserEmails: async () => [],
|
||||
addOrUpdateWorkspaceRole: async () => {},
|
||||
getWorkspaceTeam: async () => []
|
||||
getWorkspaceTeam: async () => ({ items: [], cursor: null })
|
||||
})({ workspaceId: createRandomString(), userId: createRandomString() })
|
||||
)
|
||||
|
||||
@@ -150,7 +150,7 @@ const { FF_WORKSPACES_MODULE_ENABLED } = getFeatureFlags()
|
||||
getWorkspaceWithDomains: async () => null,
|
||||
getUserEmails: async () => [],
|
||||
addOrUpdateWorkspaceRole: async () => {},
|
||||
getWorkspaceTeam: async () => []
|
||||
getWorkspaceTeam: async () => ({ items: [], cursor: null })
|
||||
})({ workspaceId: createRandomString(), userId: createRandomString() })
|
||||
)
|
||||
|
||||
@@ -185,7 +185,7 @@ const { FF_WORKSPACES_MODULE_ENABLED } = getFeatureFlags()
|
||||
workspace as unknown as WorkspaceWithDomains,
|
||||
getUserEmails: async () => [],
|
||||
addOrUpdateWorkspaceRole: async () => {},
|
||||
getWorkspaceTeam: async () => []
|
||||
getWorkspaceTeam: async () => ({ items: [], cursor: null })
|
||||
})({ workspaceId: createRandomString(), userId: createRandomString() })
|
||||
)
|
||||
|
||||
@@ -243,7 +243,7 @@ const { FF_WORKSPACES_MODULE_ENABLED } = getFeatureFlags()
|
||||
getUserEmails: async () =>
|
||||
[{ email: user.email, verified: true }] as unknown as UserEmail[],
|
||||
addOrUpdateWorkspaceRole: async () => {},
|
||||
getWorkspaceTeam: async () => []
|
||||
getWorkspaceTeam: async () => ({ items: [], cursor: null })
|
||||
})({ workspaceId: workspace.id, userId: user.id })
|
||||
).to.equal(true)
|
||||
|
||||
@@ -314,7 +314,7 @@ const { FF_WORKSPACES_MODULE_ENABLED } = getFeatureFlags()
|
||||
getUserEmails: async () =>
|
||||
[{ email: user.email, verified: true }] as unknown as UserEmail[],
|
||||
addOrUpdateWorkspaceRole: async () => {},
|
||||
getWorkspaceTeam: async () => []
|
||||
getWorkspaceTeam: async () => ({ items: [], cursor: null })
|
||||
})
|
||||
|
||||
expect(
|
||||
|
||||
Reference in New Issue
Block a user