Fix avatar and display name update issues

- Remove avatar handling from profile update to prevent overwriting DB with display URL
- Skip ensureParent for .avatars to speed up upload
- Add change detection for display name save button
- Update API client to not send avatarUrl in profile update
This commit is contained in:
Leon Bösche
2026-01-29 22:03:36 +01:00
parent b30b8eb934
commit 36de8c2313
4 changed files with 18 additions and 16 deletions

View File

@@ -91,9 +91,11 @@ func (c *WebDAVClient) Upload(ctx context.Context, remotePath string, r io.Reade
if c == nil {
return fmt.Errorf("no webdav client configured")
}
// Ensure parent collections
if err := c.ensureParent(ctx, remotePath); err != nil {
return err
// Ensure parent collections, skip for .avatars as it should exist
if !strings.HasPrefix(remotePath, ".avatars/") {
if err := c.ensureParent(ctx, remotePath); err != nil {
return err
}
}
// Construct URL
// remotePath might be like /orgs/<id>/file.txt; ensure it joins to basePrefix