Skip to content

Commit

Permalink
Fix: Wrong template for project rule when using elm-review new-package (
Browse files Browse the repository at this point in the history
#162)

Closes #161
  • Loading branch information
mateusfpleite authored and jfmengels committed Jun 22, 2024
1 parent 79d8ce2 commit 7ba6bd7
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions lib/new-package.js
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ async function create(options) {
return;
}

const ruleType = options.newRuleName || (await NewRule.askForRuleType());
const ruleType = options.ruleType || (await NewRule.askForRuleType());
if (!ruleType) {
return;
}
Expand Down Expand Up @@ -210,11 +210,7 @@ async function createProject(
writeFile(
dir,
path.join('src', `${ruleName.split('.').join('/')}.elm`),
NewRule.newSourceFile(
`${authorName}/${packageName}`,
ruleName,
options.ruleType
)
NewRule.newSourceFile(`${authorName}/${packageName}`, ruleName, ruleType)
);
writeFile(
dir,
Expand Down

0 comments on commit 7ba6bd7

Please sign in to comment.