Delegate user persistence to UserRepository

- Add create() and update() methods to UserRepository
- Update ProfileService to use repository.update()
- Update AuthService to use repository.create()
This commit is contained in:
counterweight 2025-12-25 18:52:23 +01:00
parent 17aead2e21
commit 04333d210b
Signed by: counterweight
GPG key ID: 883EDBAA726BD96C
3 changed files with 31 additions and 4 deletions

View file

@ -68,8 +68,7 @@ class ProfileService:
user.signal = data.signal
user.nostr_npub = data.nostr_npub
await self.db.commit()
await self.db.refresh(user)
await self.user_repo.update(user)
godfather_email = await self.user_repo.get_godfather_email(user.godfather_id)