Skip to content

Commit 886d058

Browse files
GustedSysoev, Vladimir
Gusted
authored and
Sysoev, Vladimir
committed
Add missing return for when topic isn't found (go-gitea#20351)
Add missing return to DeleteTopic API when the topic is not found.
1 parent b74f928 commit 886d058

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

routers/api/v1/repo/topic.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -240,6 +240,7 @@ func DeleteTopic(ctx *context.APIContext) {
240240

241241
if topic == nil {
242242
ctx.NotFound()
243+
return
243244
}
244245

245246
ctx.Status(http.StatusNoContent)

0 commit comments

Comments
 (0)