From eead53ca9979b5c40a4361a20ac00b2d6878c0c6 Mon Sep 17 00:00:00 2001 From: Vitaly Kravtsov Date: Thu, 24 Oct 2024 23:15:20 +0600 Subject: [PATCH] fix(typescript): leave resourceType field only for resource kinds --- src/aidbox_sdk/generator/typescript.clj | 1 + 1 file changed, 1 insertion(+) diff --git a/src/aidbox_sdk/generator/typescript.clj b/src/aidbox_sdk/generator/typescript.clj index c7ca52b..d3b3013 100644 --- a/src/aidbox_sdk/generator/typescript.clj +++ b/src/aidbox_sdk/generator/typescript.clj @@ -130,6 +130,7 @@ (remove nil?) ((fn [props] (if (or (fhir/base-type? ir-schema) + (not (fhir/resource? ir-schema)) (contains? (set (map :name (:elements ir-schema))) "resourceType")) props (conj props (format "resourceType: '%s'" class-name')))))