Skip to content
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

Fix: concurrency safe #32

Merged
merged 4 commits into from
Jul 27, 2023
Merged

Conversation

jonesyang12
Copy link
Contributor

Refer to this pull request #27。Unexpected errors due to context nesting, concurrency is also not safe。So I deleted the ginI18nImpl. currentContext。Manually pass in the context when calling getMessage。

@appleboy
Copy link
Member

I will take it.

@codecov-commenter
Copy link

codecov-commenter commented Jun 16, 2023

Codecov Report

Merging #32 (d138c3f) into master (f3e2f5e) will decrease coverage by 0.75%.
The diff coverage is 78.57%.

❗ Your organization is not using the GitHub App Integration. As a result you may experience degraded service beginning May 15th. Please install the Github App Integration for your organization. Read more.

@@            Coverage Diff             @@
##           master      #32      +/-   ##
==========================================
- Coverage   70.89%   70.14%   -0.75%     
==========================================
  Files           5        5              
  Lines         134      134              
==========================================
- Hits           95       94       -1     
- Misses         31       32       +1     
  Partials        8        8              
Flag Coverage Δ
go- 70.14% <78.57%> (-0.75%) ⬇️
go-1.14 65.15% <78.57%> (-0.76%) ⬇️
go-1.15 65.15% <78.57%> (-0.76%) ⬇️
go-1.16 70.14% <78.57%> (-0.75%) ⬇️
go-1.17 70.14% <78.57%> (-0.75%) ⬇️
go-1.18 70.14% <78.57%> (-0.75%) ⬇️
go-1.19 70.14% <78.57%> (-0.75%) ⬇️
go-1.20 70.14% <78.57%> (-0.75%) ⬇️
macos-latest 70.14% <78.57%> (-0.75%) ⬇️
ubuntu-latest 70.14% <78.57%> (-0.75%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
i18n.go 88.46% <70.00%> (-3.21%) ⬇️
ginI18n.go 73.17% <100.00%> (-0.64%) ⬇️

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@appleboy appleboy merged commit b8f7fd2 into gin-contrib:master Jul 27, 2023
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants