8000 Refactor context flash msg and global variables by wxiaoguang · Pull Request #33375 · go-gitea/gitea · GitHub
[go: up one dir, main page]

Skip to content

Refactor context flash msg and global variables #33375

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.

8000 Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jan 25, 2025

Conversation

wxiaoguang
Copy link
Contributor
@wxiaoguang wxiaoguang commented Jan 24, 2025
  1. add GetSiteCookieFlashMessage to help to parse flash message
  2. clarify handleRepoHomeFeed logic
  3. remove unnecessary global variables, use sync.OnceValue instead
  4. add some tests for IsUsableUsername and IsUsableRepoName

Diff with ignoring spaces: https://github.com/go-gitea/gitea/pull/33375/files?diff=unified&w=1

@GiteaBot GiteaBot added the lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. label Jan 24, 2025
@github-actions github-actions bot added the modifies/go Pull requests that update Go code label Jan 24, 2025
@wxiaoguang wxiaoguang marked this pull request as draft January 24, 2025 10:32
@silverwind silverwind added the type/refactoring Existing code has been cleaned up. There should be no new functionality. label Jan 24, 2025
@wxiaoguang wxiaoguang changed the title Refactor context flash msg Refactor context flash msg and name global variables Jan 24, 2025
@wxiaoguang wxiaoguang changed the title Refactor context flash msg and name global variables Refactor context flash msg and name global variables Jan 24, 2025
@wxiaoguang wxiaoguang force-pushed the refactor-context branch 4 times, most recently from 21a032a to dd99137 Compare January 24, 2025 12:49
@wxiaoguang wxiaoguang marked this pull request as ready for review January 24, 2025 12:49
@wxiaoguang wxiaoguang requested review from Zettat123 and lunny January 24, 2025 12:49
@wxiaoguang wxiaoguang changed the title Refactor context flash msg and name global variables Refactor context flash msg and global variables Jan 24, 2025
@GiteaBot GiteaBot added lgtm/need 1 This PR needs approval from one additional maintainer to be merged. and removed lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. labels Jan 24, 2025
@GiteaBot GiteaBot removed the lgtm/need 1 This PR needs approval from one additional maintainer to be merged. label Jan 25, 2025
@GiteaBot GiteaBot added the lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. label Jan 25, 2025
@wxiaoguang wxiaoguang enabled auto-merge (squash) January 25, 2025 14:29
@wxiaoguang wxiaoguang merged commit 2c1ff87 into go-gitea:main Jan 25, 2025
26 checks passed
@GiteaBot GiteaBot added this to the 1.24.0 milestone Jan 25, 2025
@wxiaoguang wxiaoguang deleted the refactor-context branch January 25, 2025 14:39
@go-gitea go-gitea locked as resolved and limited conversation to collaborators Apr 25, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
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/refactoring Existing code has been cleaned up. There should be no new functionality.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants
0