mirror of
https://github.com/Memo-2023/mana-monorepo.git
synced 2026-05-14 21:21:10 +02:00
fix(mana-media): change userId from UUID to TEXT for Matrix user IDs
Matrix user IDs like @user:matrix.org are not UUIDs, so the schema needs to accept text strings for the userId field in media_references. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
parent
cee30ff7ed
commit
5c19500748
1 changed files with 2 additions and 2 deletions
|
|
@ -65,8 +65,8 @@ export const mediaReferences = pgTable(
|
|||
mediaId: uuid('media_id')
|
||||
.references(() => media.id, { onDelete: 'cascade' })
|
||||
.notNull(),
|
||||
// Owner info
|
||||
userId: uuid('user_id').notNull(),
|
||||
// Owner info (can be UUID or Matrix user ID like @user:matrix.org)
|
||||
userId: text('user_id').notNull(),
|
||||
// Source app (nutriphi, contacts, chat, etc.)
|
||||
app: text('app').notNull(),
|
||||
// Optional: reference to the source (e.g., mxc:// URL from Matrix)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue