Skip to content

Commit

Permalink
try spread
Browse files Browse the repository at this point in the history
  • Loading branch information
weidongxu-microsoft committed Jun 17, 2024
1 parent e631d18 commit f52a0e1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion typespec-extension/src/code-model-builder.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1347,7 +1347,7 @@ export class CodeModelBuilder {
schema = this.processSchemaFromSdkType(sdkType, body.name);
}

const isAnonymousModel = sdkType.kind === "model" && sdkType.isGeneratedName === true;
const isAnonymousModel = body.kind === "ModelProperty";
const parameterName = body.kind === "Model" ? (sdkType.kind === "model" ? sdkType.name : "") : this.getName(body);
const parameter = new Parameter(parameterName, this.getDoc(body), schema, {
summary: this.getSummary(body),
Expand Down

0 comments on commit f52a0e1

Please sign in to comment.