diff --git a/package.json b/package.json index ab02d5af..accca1ea 100644 --- a/package.json +++ b/package.json @@ -28,7 +28,7 @@ "test:fixed": "mocha --config=test/unit/.mocharc.json --node-env=test --exit 'test/unit/pools/fixedRate/FixedRateExchange.test.ts'", "test:pool": "mocha --config=test/unit/.mocharc.json --node-env=test --exit 'test/unit/pools/balancer/Pool.test.ts'", "test:dispenser": "mocha --config=test/unit/.mocharc.json --node-env=test --exit 'test/unit/pools/dispenser/Dispenser.test.ts'", - "test:dt": "mocha --config=test/unit/.mocharc.json --node-env=test --exit 'test/unit/Datatoken.test.ts'", + "test:dt": "mocha --config=test/unit/.mocharc.json --node-env=test --exit 'test/unit/tokens/Datatoken.test.ts'", "test:nftDt": "mocha --config=test/unit/.mocharc.json --node-env=test --exit 'test/unit/tokens/Nft.test.ts'", "test:factory": "mocha --config=test/unit/.mocharc.json --node-env=test --exit 'test/unit/NFTFactory.test.ts'", "test:router": "mocha --config=test/unit/.mocharc.json --node-env=test --exit 'test/unit/pools/Router.test.ts'", diff --git a/src/factories/NFTFactory.ts b/src/factories/NFTFactory.ts index 1ca179b1..e4c207d6 100644 --- a/src/factories/NFTFactory.ts +++ b/src/factories/NFTFactory.ts @@ -108,14 +108,14 @@ export class NftFactory { nftData.name = name nftData.symbol = symbol } - if ( nftData.templateIndex > await this.getCurrentNFTTemplateCount()) { + if (nftData.templateIndex > (await this.getCurrentNFTTemplateCount())) { throw new Error(`Template index doesnt exist`) } - if ( nftData.templateIndex === 0) { + if (nftData.templateIndex === 0) { throw new Error(`Template index cannot be ZERO`) } - if((await this.getNFTTemplate(nftData.templateIndex)).isActive === false) { + if ((await this.getNFTTemplate(nftData.templateIndex)).isActive === false) { throw new Error(`Template is not active`) } const estGas = await this.estGasCreateNFT(address, nftData) @@ -189,11 +189,11 @@ export class NftFactory { * @return {Promise