[PR #2565] [MERGED] fix: reset SSO avatar provider to default when picture claim is removed #8368

Closed
opened 2026-04-20 18:10:39 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/go-vikunja/vikunja/pull/2565
Author: @tink-bot
Created: 4/8/2026
Status: Merged
Merged: 4/8/2026
Merged by: @kolaente

Base: mainHead: fix-avatar-sso-reset


📝 Commits (4)

  • 49a366e test: add tests for SSO avatar provider reset on empty picture URL
  • 45031ff fix: reset SSO avatar provider to default when picture claim is removed
  • cadb793 fix: use assert.Empty instead of assert.Equal for empty string check
  • ce1f412 fix: update user list test expectations for new fixture user

📊 Changes

4 files changed (+68 additions, -4 deletions)

View changed files

📝 pkg/db/fixtures/users.yml (+10 -0)
📝 pkg/models/user_list_test.go (+2 -2)
📝 pkg/modules/auth/openid/openid.go (+10 -2)
📝 pkg/modules/auth/openid/openid_test.go (+46 -0)

📄 Description

When a user removes their profile picture from their OpenID Connect identity provider, Vikunja kept the avatar provider set to "openid", resulting in a broken avatar. This resets it to "default" when the OIDC picture claim is empty, while respecting manually chosen providers like gravatar or upload.

Relates to #2217


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/go-vikunja/vikunja/pull/2565 **Author:** [@tink-bot](https://github.com/tink-bot) **Created:** 4/8/2026 **Status:** ✅ Merged **Merged:** 4/8/2026 **Merged by:** [@kolaente](https://github.com/kolaente) **Base:** `main` ← **Head:** `fix-avatar-sso-reset` --- ### 📝 Commits (4) - [`49a366e`](https://github.com/go-vikunja/vikunja/commit/49a366e7c44a9671aa49bcfc405fb2422c962528) test: add tests for SSO avatar provider reset on empty picture URL - [`45031ff`](https://github.com/go-vikunja/vikunja/commit/45031ff5a73ceac253d5e8747657f22491198e87) fix: reset SSO avatar provider to default when picture claim is removed - [`cadb793`](https://github.com/go-vikunja/vikunja/commit/cadb793bbf5025520ff07f9c06042359f98e7099) fix: use assert.Empty instead of assert.Equal for empty string check - [`ce1f412`](https://github.com/go-vikunja/vikunja/commit/ce1f4121c7c0c535e458a19f16f9087230cbf095) fix: update user list test expectations for new fixture user ### 📊 Changes **4 files changed** (+68 additions, -4 deletions) <details> <summary>View changed files</summary> 📝 `pkg/db/fixtures/users.yml` (+10 -0) 📝 `pkg/models/user_list_test.go` (+2 -2) 📝 `pkg/modules/auth/openid/openid.go` (+10 -2) 📝 `pkg/modules/auth/openid/openid_test.go` (+46 -0) </details> ### 📄 Description When a user removes their profile picture from their OpenID Connect identity provider, Vikunja kept the avatar provider set to "openid", resulting in a broken avatar. This resets it to "default" when the OIDC picture claim is empty, while respecting manually chosen providers like gravatar or upload. Relates to #2217 --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2026-04-20 18:10:39 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/vikunja#8368