repo: Admin can override default expected tag
This commit is contained in:
parent
20016a99c6
commit
1859a715df
3 changed files with 34 additions and 4 deletions
|
|
@ -189,7 +189,12 @@ func declareAPIAuthRepositoriesRoutes(router *gin.RouterGroup) {
|
|||
return
|
||||
}
|
||||
|
||||
TriggerTagUpdate(c, work, repo, u, nil)
|
||||
var tag *string
|
||||
if loggeduser.IsAdmin {
|
||||
c.ShouldBindJSON(&tag)
|
||||
}
|
||||
|
||||
TriggerTagUpdate(c, work, repo, u, tag)
|
||||
})
|
||||
|
||||
repositoriesRoutes.GET("/state", func(c *gin.Context) {
|
||||
|
|
|
|||
Reference in a new issue