forked from loafle/openapi-generator-original
[Issue#392] Correct issue with OAuth scopes not propogated correctly (#1982)
If a path defined security to an OAuth type, and defined scopes, the scopes from the components definition were still being used, rather than the (most likely shorter) list of specific scopes for the path. This copies all the component security information over EXCEPT for the scopes. The scopes to be included are determined by the path's security settings. NOTE: Modified the petstore.yaml file so the GET operations only have read:pets scope and utilized the Kotlin server sample to verify output. Sample output updated only for this scenario
This commit is contained in:
committed by
William Cheng
parent
b5ede4b339
commit
67b3766332
@@ -1,24 +0,0 @@
|
||||
package org.openapitools.model
|
||||
|
||||
import java.util.Objects
|
||||
import com.fasterxml.jackson.annotation.JsonProperty
|
||||
import javax.validation.Valid
|
||||
import javax.validation.constraints.*
|
||||
import io.swagger.annotations.ApiModelProperty
|
||||
|
||||
/**
|
||||
* A category for a pet
|
||||
* @param id
|
||||
* @param name
|
||||
*/
|
||||
data class Category (
|
||||
|
||||
@ApiModelProperty(example = "null", value = "")
|
||||
@JsonProperty("id") val id: Long? = null,
|
||||
|
||||
@ApiModelProperty(example = "null", value = "")
|
||||
@JsonProperty("name") val name: String? = null
|
||||
) {
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user