diff options
author | Antoine GIRARD <sapk@users.noreply.github.com> | 2019-08-26 20:13:10 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-08-26 20:13:10 +0200 |
commit | 954fe0e4e0ab61516f200a171cf9a3bfb49c8906 (patch) | |
tree | a5b4dacce7847f40a98a208fd384151f885efbb0 /templates | |
parent | 042089fbaf8a818042405a75bee08dea8db347c0 (diff) | |
download | gitea-954fe0e4e0ab61516f200a171cf9a3bfb49c8906.tar.gz gitea-954fe0e4e0ab61516f200a171cf9a3bfb49c8906.zip |
swagger/fix: []string are not enum by swagger definition (#7916)
* []string are not enum by swagger definition
* apply suggestion of @guillep2k
* re-generate swagger file
Diffstat (limited to 'templates')
-rw-r--r-- | templates/swagger/v1_json.tmpl | 36 |
1 files changed, 18 insertions, 18 deletions
diff --git a/templates/swagger/v1_json.tmpl b/templates/swagger/v1_json.tmpl index de670156de..2e4af809e8 100644 --- a/templates/swagger/v1_json.tmpl +++ b/templates/swagger/v1_json.tmpl @@ -7742,7 +7742,11 @@ }, "units": { "type": "array", - "enum": [ + "items": { + "type": "string" + }, + "x-go-name": "Units", + "example": [ "repo.code", "repo.issues", "repo.ext_issues", @@ -7750,11 +7754,7 @@ "repo.pulls", "repo.releases", "repo.ext_wiki" - ], - "items": { - "type": "string" - }, - "x-go-name": "Units" + ] } }, "x-go-package": "code.gitea.io/gitea/modules/structs" @@ -8276,7 +8276,11 @@ }, "units": { "type": "array", - "enum": [ + "items": { + "type": "string" + }, + "x-go-name": "Units", + "example": [ "repo.code", "repo.issues", "repo.ext_issues", @@ -8284,11 +8288,7 @@ "repo.pulls", "repo.releases", "repo.ext_wiki" - ], - "items": { - "type": "string" - }, - "x-go-name": "Units" + ] } }, "x-go-package": "code.gitea.io/gitea/modules/structs" @@ -9827,7 +9827,11 @@ }, "units": { "type": "array", - "enum": [ + "items": { + "type": "string" + }, + "x-go-name": "Units", + "example": [ "repo.code", "repo.issues", "repo.ext_issues", @@ -9835,11 +9839,7 @@ "repo.pulls", "repo.releases", "repo.ext_wiki" - ], - "items": { - "type": "string" - }, - "x-go-name": "Units" + ] } }, "x-go-package": "code.gitea.io/gitea/modules/structs" |