Skip to content

Commit

Permalink
fix: convert instructions model name to pascalcase
Browse files Browse the repository at this point in the history
Fixes: #204
  • Loading branch information
Harminder Virk authored and Harminder Virk committed Aug 15, 2022
1 parent 946e730 commit 31aa47a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion instructions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -398,7 +398,7 @@ export default async function instructions(
const modelName = await getModelName(sink)
state.modelName = modelName.replace(/(\.ts|\.js)$/, '')
state.usersTableName = string.pluralize(string.snakeCase(state.modelName))
state.modelReference = string.camelCase(state.modelName)
state.modelReference = string.pascalCase(string.singularize(state.modelName))
state.modelNamespace = `${app.namespacesMap.get('models') || 'App/Models'}/${state.modelName}`
} else {
state.usersTableName = await getTableName(sink)
Expand Down

0 comments on commit 31aa47a

Please sign in to comment.