From 7a6f1a322759a9caf3b780f58b453a485a33e472 Mon Sep 17 00:00:00 2001 From: Shimizu1111 Date: Thu, 7 Sep 2023 18:08:31 +0900 Subject: [PATCH] When the return value defined by the @Success tag is equal to a null value, make fixes to prevent a null pointer exception occurs --- operation.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/operation.go b/operation.go index edf251002..9a02c0fd4 100644 --- a/operation.go +++ b/operation.go @@ -918,6 +918,10 @@ func parseCombinedObjectSchema(parser *Parser, refType string, astFile *ast.File return nil, err } + if schema == nil { + schema = PrimitiveSchema(OBJECT) + } + props[keyVal[0]] = *schema } }