diff --git a/Swagger.Net/Swagger/Extensions/SchemaExtensions.cs b/Swagger.Net/Swagger/Extensions/SchemaExtensions.cs index ca1dcd0..6c9ec02 100644 --- a/Swagger.Net/Swagger/Extensions/SchemaExtensions.cs +++ b/Swagger.Net/Swagger/Extensions/SchemaExtensions.cs @@ -89,7 +89,10 @@ public static Schema WithDescriptionProperty(this Schema schema, JsonProperty js return schema; var attrib = propInfo.GetCustomAttributes(false).OfType().FirstOrDefault(); - schema.description = attrib?.Description; + var description = attrib?.Description; + if (description != null) + schema.description = description; + return schema; }