-
-
Notifications
You must be signed in to change notification settings - Fork 5.8k
Return default avatar url when user id is zero rather than updating database #34094
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
techknowlogick
approved these changes
Apr 1, 2025
techknowlogick
requested changes
Apr 1, 2025
Co-authored-by: techknowlogick <techknowlogick@gitea.io>
techknowlogick
approved these changes
Apr 1, 2025
a1012112796
approved these changes
Apr 2, 2025
GiteaBot
pushed a commit
to GiteaBot/gitea
that referenced
this pull request
Apr 2, 2025
techknowlogick
pushed a commit
that referenced
this pull request
Apr 2, 2025
…atabase (#34094) (#34095) Backport #34094 by @lunny When visit commit list, it would update the user avatar even if id = 0, which was unnecessary operations. This PR returned default avatar for the git only user avatar rendering who's user id is zero. ```log database duration=0.0005s db.sql="UPDATE `user` SET `avatar` = ?, `updated_unix` = ? WHERE `id`=?" database duration=0.0007s db.sql="UPDATE `user` SET `avatar` = ?, `updated_unix` = ? WHERE `id`=?" ... ``` Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
zjjhot
added a commit
to zjjhot/gitea
that referenced
this pull request
Apr 3, 2025
* giteaofficial/main: Refactor Branch struct in package modules/git (go-gitea#33980) Support creating relative link to raw path in markdown (go-gitea#34105) Add new CLI flags to set name and scopes when creating a user with access token (go-gitea#34080) Do not show 500 error when default branch doesn't exist (go-gitea#34096) Return default avatar url when user id is zero rather than updating database (go-gitea#34094) [skip ci] Updated translations via Crowdin Fix return bug (go-gitea#34093) Move ParseCommitWithSSHSignature to service layer (go-gitea#34087) fix(i18n): clarify ownership in password change error messages (go-gitea#34092) Enable addtional linters (go-gitea#34085) Add flat-square action badge style (go-gitea#34062) Fix some UI bugs and clean up unused tests (go-gitea#34088)
project-mirrors-bot-tu bot
pushed a commit
to project-mirrors/forgejo-as-gitea-fork
that referenced
this pull request
Apr 13, 2025
…atabase (go-gitea#34094) (cherry picked from commit 88352e0)
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
backport/done
All backports for this PR have been created
backport/v1.23
This PR should be backported to Gitea 1.23
lgtm/done
This PR has enough approvals to get merged. There are no important open reservations anymore.
modifies/go
Pull requests that update Go code
type/bug
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
When visit commit list, it would update the user avatar even if id = 0, which was unnecessary operations. This PR returned default avatar for the git only user avatar rendering who's user id is zero.