diff options
author | Joe Chen <jc@unknwon.io> | 2022-06-11 11:54:11 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-06-11 11:54:11 +0800 |
commit | 5e32058c13f34b46c69b7cdee6ccc0b7fe3b6df3 (patch) | |
tree | 92353ba2d8b6461754b89e95f581f4d402cf42af /internal/db/user.go | |
parent | 75fbb8244086a2ad964d1c51e3bdbdfb95df90ac (diff) |
db: use `context` and go-mockgen for `TwoFactorsStore` (#7045)
Diffstat (limited to 'internal/db/user.go')
-rw-r--r-- | internal/db/user.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/internal/db/user.go b/internal/db/user.go index ebfbf082..1ad4b955 100644 --- a/internal/db/user.go +++ b/internal/db/user.go @@ -405,7 +405,7 @@ func (u *User) IsPublicMember(orgId int64) bool { // IsEnabledTwoFactor returns true if user has enabled two-factor authentication. func (u *User) IsEnabledTwoFactor() bool { - return TwoFactors.IsUserEnabled(u.ID) + return TwoFactors.IsUserEnabled(context.TODO(), u.ID) } func (u *User) getOrganizationCount(e Engine) (int64, error) { |