Fixes some typos
This commit is contained in:
Nicolas
2026-04-21 21:56:14 +02:00
committed by GitHub
parent b4f48a64fc
commit 732e23258e
12 changed files with 28 additions and 28 deletions

View File

@@ -217,7 +217,7 @@ func (app *OAuth2Application) GetGrantByUserID(ctx context.Context, userID int64
return grant, nil
}
// CreateGrant generates a grant for an user
// CreateGrant generates a grant for a user
func (app *OAuth2Application) CreateGrant(ctx context.Context, userID int64, scope string) (*OAuth2Grant, error) {
grant := &OAuth2Grant{
ApplicationID: app.ID,
@@ -461,7 +461,7 @@ func GetOAuth2AuthorizationByCode(ctx context.Context, code string) (auth *OAuth
//////////////////////////////////////////////////////
// OAuth2Grant represents the permission of an user for a specific application to access resources
// OAuth2Grant represents the permission of a user for a specific application to access resources
type OAuth2Grant struct {
ID int64 `xorm:"pk autoincr"`
UserID int64 `xorm:"INDEX unique(user_application)"`

View File

@@ -67,7 +67,7 @@ func GetIssueWatch(ctx context.Context, userID, issueID int64) (iw *IssueWatch,
return iw, exists, err
}
// CheckIssueWatch check if an user is watching an issue
// CheckIssueWatch check if a user is watching an issue
// it takes participants and repo watch into account
func CheckIssueWatch(ctx context.Context, user *user_model.User, issue *Issue) (bool, error) {
iw, exist, err := GetIssueWatch(ctx, user.ID, issue.ID)

View File

@@ -67,7 +67,7 @@ func (err ErrNotValidReviewRequest) Unwrap() error {
return util.ErrInvalidArgument
}
// ErrReviewRequestOnClosedPR represents an error when an user tries to request a re-review on a closed or merged PR.
// ErrReviewRequestOnClosedPR represents an error when a user tries to request a re-review on a closed or merged PR.
type ErrReviewRequestOnClosedPR struct{}
// IsErrReviewRequestOnClosedPR checks if an error is an ErrReviewRequestOnClosedPR.

View File

@@ -11,7 +11,7 @@ import (
"code.gitea.io/gitea/modules/timeutil"
)
// Star represents a starred repo by an user.
// Star represents a starred repo by a user.
type Star struct {
ID int64 `xorm:"pk autoincr"`
UID int64 `xorm:"UNIQUE(s)"`