Skip to content

Commit

Permalink
chore: fix source generator
Browse files Browse the repository at this point in the history
  • Loading branch information
pviti committed Dec 18, 2024
1 parent 0566270 commit 7573ae5
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion gen/generator.ts
Original file line number Diff line number Diff line change
Expand Up @@ -744,7 +744,7 @@ const generateResource = (type: string, name: string, resource: Resource): strin

// Resources import
const impResMod: string[] = Array.from(declaredImportsModels)
.filter(i => !typesArray.includes(i)) // exludes resource self reference
.filter(i => !typesArray.includes(i)) // excludes resource self reference
.map(i => `import type { ${i}${relationshipTypes.has(i) ? `, ${i}Type` : ''} } from './${Inflector.underscore(Inflector.pluralize(i))}'`)
const importStr = impResMod.join('\n') + (impResMod.length ? '\n' : '')
res = res.replace(/##__IMPORT_RESOURCE_MODELS__##/g, importStr)
Expand Down
2 changes: 1 addition & 1 deletion gen/templates/spec_trigger.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ it(resourceType + '.##__OPERATION_NAME__##', async () => {

const triggerValue = ##__TRIGGER_VALUE__##
const attributes = { [triggerAttr]: triggerValue }
const id = TestData.id
const id = TestData.id

const intId = cl.addRequestInterceptor((request) => {
const data = JSON.parse(String(request.options.body))
Expand Down

0 comments on commit 7573ae5

Please sign in to comment.