Skip to content
This repository has been archived by the owner on Nov 3, 2023. It is now read-only.

Commit

Permalink
fix: short switch linter error
Browse files Browse the repository at this point in the history
  • Loading branch information
MqllR committed Jul 1, 2022
1 parent c1605d3 commit 001e34f
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,5 +26,5 @@ jobs:

- uses: reviewdog/action-eslint@v1
with:
reporter: github-pr-review
reporter: github-check
filter_mode: nofilter
9 changes: 4 additions & 5 deletions src/lib/NFT/contractFactory.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,10 @@ import ERC721Mintable from '../ContractTemplates/ERC721Mintable.js';

export default class ContractFactory {
static factory(template, signer) {
switch (template) {
case TEMPLATES.ERC721Mintable:
return new ERC721Mintable(signer);
default:
throw new Error('Invalid template provided');
if (template === TEMPLATES.ERC721Mintable) {
return new ERC721Mintable(signer);
}

throw new Error('Invalid template provided');
}
}

0 comments on commit 001e34f

Please sign in to comment.