feat(server): cleanup legacy compatibility (#15239)

This commit is contained in:
DarkSky
2026-07-15 03:01:51 +08:00
committed by GitHub
parent 00d4ab10a1
commit e145d87d56
104 changed files with 3184 additions and 8883 deletions
+5 -3
View File
@@ -88,12 +88,14 @@ export async function addUserToWorkspace(
if (workspace == null) {
throw new Error(`workspace ${workspaceId} not found`);
}
await client.workspaceUserRole.create({
await client.workspaceMember.create({
data: {
workspaceId: workspace.id,
userId,
status: 'Accepted',
type: permission,
role:
permission === 99 ? 'owner' : permission === 10 ? 'admin' : 'member',
state: 'active',
source: 'legacy',
},
});
});