mirror of
https://github.com/go-gitea/gitea.git
synced 2024-12-18 11:28:39 +08:00
parseScope with owner/repo always sets owner to zero (#25987)
Refs: https://codeberg.org/forgejo/forgejo/pulls/1001
This commit is contained in:
parent
0f9f6567bb
commit
ad4c09b59f
@ -77,9 +77,10 @@ func parseScope(ctx *context.PrivateContext, scope string) (ownerID, repoID int6
|
|||||||
if err != nil {
|
if err != nil {
|
||||||
return ownerID, repoID, err
|
return ownerID, repoID, err
|
||||||
}
|
}
|
||||||
|
ownerID = u.ID
|
||||||
|
|
||||||
if !found {
|
if !found {
|
||||||
return u.ID, repoID, nil
|
return ownerID, repoID, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
r, err := repo_model.GetRepositoryByName(u.ID, repoName)
|
r, err := repo_model.GetRepositoryByName(u.ID, repoName)
|
||||||
|
Loading…
Reference in New Issue
Block a user