From 3142134d382a5673d170e73a170506a5528e0d56 Mon Sep 17 00:00:00 2001 From: "Mingzhe Huang (from Dev Box)" Date: Mon, 29 Jul 2024 15:09:25 +0800 Subject: [PATCH] update default value definition --- packages/cadl-ranch-expect/src/decorators.ts | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/packages/cadl-ranch-expect/src/decorators.ts b/packages/cadl-ranch-expect/src/decorators.ts index 91a0a4087..1048da38e 100644 --- a/packages/cadl-ranch-expect/src/decorators.ts +++ b/packages/cadl-ranch-expect/src/decorators.ts @@ -243,17 +243,8 @@ export function $scenarioService( kind: "Model", properties: new Map().set("endpoint", { name: "endpoint", - type: { - kind: "Scalar", - name: "string", - derivedScalars: [], - projections: [], - projectionsByName: [], - isFinished: false, - decorators: [], - namespace: { kind: "Namespace", name: "TypeSpec", namespace: context.program.getGlobalNamespaceType() }, - }, - default: { kind: "String", value: "http://localhost:3000" }, + type: context.program!.getGlobalNamespaceType().namespaces.get("TypeSpec")!.scalars.get("string"), + defaultValue: { kind: "String", value: "http://localhost:3000" }, }), decorators: [], projections: [],