mirror of
https://github.com/woodpecker-ci/woodpecker.git
synced 2026-03-15 17:13:46 +01:00
Enforce exact matching for GitLab groups (#4473)
This commit is contained in:
@@ -130,7 +130,7 @@ func PostRepo(c *gin.Context) {
|
||||
if errors.Is(err, types.RecordNotExist) {
|
||||
org, err = _forge.Org(c, user, repo.Owner)
|
||||
if err != nil {
|
||||
msg := "could not fetch organization from forge."
|
||||
msg := fmt.Sprintf("Organization %s not found in DB. Attempting to create new one.", repo.Owner)
|
||||
log.Error().Err(err).Msg(msg)
|
||||
c.String(http.StatusInternalServerError, msg)
|
||||
return
|
||||
@@ -139,7 +139,7 @@ func PostRepo(c *gin.Context) {
|
||||
org.ForgeID = user.ForgeID
|
||||
err = _store.OrgCreate(org)
|
||||
if err != nil {
|
||||
msg := "could not create organization in store."
|
||||
msg := fmt.Sprintf("Failed to create organization %s.", repo.Owner)
|
||||
log.Error().Err(err).Msg(msg)
|
||||
c.String(http.StatusInternalServerError, msg)
|
||||
return
|
||||
|
||||
Reference in New Issue
Block a user