mirror of
https://github.com/Redocly/redoc.git
synced 2025-01-31 10:04:08 +03:00
fix: writeOnly not respected in response samples
This commit is contained in:
parent
0f1b6a622e
commit
87abdf79d8
|
@ -45,7 +45,7 @@ export class MediaTypeModel {
|
|||
this.examples[subSchema.title] = {
|
||||
value: Sampler.sample(
|
||||
subSchema.rawSchema,
|
||||
{ skipReadOnly: this.isRequestType, skipReadWrite: !this.isRequestType },
|
||||
{ skipReadOnly: this.isRequestType, skipWriteOnly: !this.isRequestType },
|
||||
parser.spec,
|
||||
),
|
||||
};
|
||||
|
@ -55,7 +55,7 @@ export class MediaTypeModel {
|
|||
default: new ExampleModel(parser, {
|
||||
value: Sampler.sample(
|
||||
info.schema,
|
||||
{ skipReadOnly: this.isRequestType, skipReadWrite: !this.isRequestType },
|
||||
{ skipReadOnly: this.isRequestType, skipWriteOnly: !this.isRequestType },
|
||||
parser.spec,
|
||||
),
|
||||
}),
|
||||
|
|
Loading…
Reference in New Issue
Block a user