mirror of
https://github.com/go-gitea/gitea.git
synced 2026-10-08 07:49:50 +02:00
Remove incorrect "db.DefaultContext" usages (#35366)
This commit is contained in:
1 parent
7aef7ea2d4
commit
0cbaa0b662
256 files changed
+1951
-2098
No files matched your search
@@ -9,7 +9,6 @@ import (
|
||||
"time"
|
||||
|
||||
auth_model "code.gitea.io/gitea/models/auth"
|
||||
"code.gitea.io/gitea/models/db"
|
||||
"code.gitea.io/gitea/models/unittest"
|
||||
user_model "code.gitea.io/gitea/models/user"
|
||||
"code.gitea.io/gitea/tests"
|
||||
@@ -39,7 +38,7 @@ func TestAPITwoFactor(t *testing.T) {
|
||||
}
|
||||
assert.NoError(t, tfa.SetSecret(otpKey.Secret()))
|
||||
|
||||
assert.NoError(t, auth_model.NewTwoFactor(db.DefaultContext, tfa))
|
||||
assert.NoError(t, auth_model.NewTwoFactor(t.Context(), tfa))
|
||||
|
||||
req = NewRequest(t, "GET", "/api/v1/user").
|
||||
AddBasicAuth(user.Name)
|
||||
|
||||
Reference in new issue
Block a user