mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2024-12-26 14:44:05 +01:00
document 404 responce and meaning (#11073)
This commit is contained in:
parent
2e85ad665a
commit
70fab7e26a
2 changed files with 5 additions and 0 deletions
|
@ -114,6 +114,8 @@ func IsWatching(ctx *context.APIContext) {
|
||||||
// responses:
|
// responses:
|
||||||
// "200":
|
// "200":
|
||||||
// "$ref": "#/responses/WatchInfo"
|
// "$ref": "#/responses/WatchInfo"
|
||||||
|
// "404":
|
||||||
|
// description: User is not watching this repo or repo do not exist
|
||||||
|
|
||||||
if models.IsWatching(ctx.User.ID, ctx.Repo.Repository.ID) {
|
if models.IsWatching(ctx.User.ID, ctx.Repo.Repository.ID) {
|
||||||
ctx.JSON(http.StatusOK, api.WatchInfo{
|
ctx.JSON(http.StatusOK, api.WatchInfo{
|
||||||
|
|
|
@ -7411,6 +7411,9 @@
|
||||||
"responses": {
|
"responses": {
|
||||||
"200": {
|
"200": {
|
||||||
"$ref": "#/responses/WatchInfo"
|
"$ref": "#/responses/WatchInfo"
|
||||||
|
},
|
||||||
|
"404": {
|
||||||
|
"description": "User is not watching this repo or repo do not exist"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
Loading…
Reference in a new issue