Skip to content

Commit

Permalink
fix: use contract wrappers version with fixed addModuleWithLabel
Browse files Browse the repository at this point in the history
fix #101
  • Loading branch information
monitz87 committed Oct 27, 2019
1 parent d607c7f commit d70df68
Show file tree
Hide file tree
Showing 11 changed files with 110 additions and 150 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@
"@0x/subproviders": "^3.0.2",
"@babel/polyfill": "^7.0.0",
"@babel/runtime": "^7.2.0",
"@polymathnetwork/contract-wrappers": "3.0.0-beta.47",
"@polymathnetwork/contract-wrappers": "3.0.0-beta.52",
"@types/sinon": "^7.5.0",
"bluebird": "^3.5.5",
"ethereum-address": "^0.0.4",
Expand Down
4 changes: 2 additions & 2 deletions src/entities/factories/CappedStoFactory.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import {
BlockParamLiteral,
conversionUtils,
FULL_DECIMALS,
CappedSTOEvents_3_0_0,
CappedSTOEvents,
} from '@polymathnetwork/contract-wrappers';
import { Factory } from './Factory';
import { Context } from '../../Context';
Expand All @@ -26,7 +26,7 @@ export class CappedStoFactory extends Factory<CappedSto, Params, UniqueIdentifie
});

const tokenPurchases = await module.getLogsAsync({
eventName: CappedSTOEvents_3_0_0.TokenPurchase,
eventName: CappedSTOEvents.TokenPurchase,
blockRange: {
fromBlock: BlockParamLiteral.Earliest,
toBlock: BlockParamLiteral.Latest,
Expand Down
8 changes: 4 additions & 4 deletions src/entities/factories/InvestmentFactory.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ import {
BlockParamLiteral,
conversionUtils,
FULL_DECIMALS,
CappedSTOEvents_3_0_0,
USDTieredSTOEvents_3_0_0,
CappedSTOEvents,
USDTieredSTOEvents,
} from '@polymathnetwork/contract-wrappers';
import { Factory } from './Factory';
import { Context } from '../../Context';
Expand All @@ -30,7 +30,7 @@ export class InvestmentFactory extends Factory<Investment, Params, UniqueIdentif
});

const tokenPurchases = await module.getLogsAsync({
eventName: CappedSTOEvents_3_0_0.TokenPurchase,
eventName: CappedSTOEvents.TokenPurchase,
blockRange: {
fromBlock: BlockParamLiteral.Earliest,
toBlock: BlockParamLiteral.Latest,
Expand Down Expand Up @@ -64,7 +64,7 @@ export class InvestmentFactory extends Factory<Investment, Params, UniqueIdentif
});

const tokenPurchases = await module.getLogsAsync({
eventName: USDTieredSTOEvents_3_0_0.TokenPurchase,
eventName: USDTieredSTOEvents.TokenPurchase,
blockRange: {
fromBlock: BlockParamLiteral.Earliest,
toBlock: BlockParamLiteral.Latest,
Expand Down
4 changes: 2 additions & 2 deletions src/entities/factories/UsdTieredStoFactory.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import {
ModuleName,
USDTieredSTOEvents_3_0_0,
USDTieredSTOEvents,
BlockParamLiteral,
conversionUtils,
FULL_DECIMALS,
Expand All @@ -27,7 +27,7 @@ export class UsdTieredStoFactory extends Factory<UsdTieredSto, Params, UniqueIde
});

const tokenPurchases = await module.getLogsAsync({
eventName: USDTieredSTOEvents_3_0_0.TokenPurchase,
eventName: USDTieredSTOEvents.TokenPurchase,
blockRange: {
fromBlock: BlockParamLiteral.Earliest,
toBlock: BlockParamLiteral.Latest,
Expand Down
4 changes: 2 additions & 2 deletions src/procedures/CreateCheckpoint.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { SecurityTokenEvents_3_0_0 } from '@polymathnetwork/contract-wrappers';
import { SecurityTokenEvents } from '@polymathnetwork/contract-wrappers';
import { Procedure } from './Procedure';
import {
CreateCheckpointProcedureArgs,
Expand Down Expand Up @@ -38,7 +38,7 @@ export class CreateCheckpoint extends Procedure<CreateCheckpointProcedureArgs, C

const [event] = findEvents({
logs,
eventName: SecurityTokenEvents_3_0_0.CheckpointCreated,
eventName: SecurityTokenEvents.CheckpointCreated,
});
if (event) {
const { args: eventArgs } = event;
Expand Down
4 changes: 2 additions & 2 deletions src/procedures/CreateErc20DividendDistribution.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import {
ModuleName,
ERC20DividendCheckpointEvents_3_0_0,
ERC20DividendCheckpointEvents,
BigNumber,
} from '@polymathnetwork/contract-wrappers';
import { Procedure } from './Procedure';
Expand Down Expand Up @@ -75,7 +75,7 @@ export class CreateErc20DividendDistribution extends Procedure<
const { logs } = receipt;

const [event] = findEvents({
eventName: ERC20DividendCheckpointEvents_3_0_0.ERC20DividendDeposited,
eventName: ERC20DividendCheckpointEvents.ERC20DividendDeposited,
logs,
});

Expand Down
4 changes: 2 additions & 2 deletions src/procedures/CreateEtherDividendDistribution.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import {
ModuleName,
EtherDividendCheckpointEvents_3_0_0,
EtherDividendCheckpointEvents,
BigNumber,
} from '@polymathnetwork/contract-wrappers';
import { Procedure } from './Procedure';
Expand Down Expand Up @@ -67,7 +67,7 @@ export class CreateEtherDividendDistribution extends Procedure<
const { logs } = receipt;

const [event] = findEvents({
eventName: EtherDividendCheckpointEvents_3_0_0.EtherDividendDeposited,
eventName: EtherDividendCheckpointEvents.EtherDividendDeposited,
logs,
});

Expand Down
4 changes: 2 additions & 2 deletions src/procedures/LaunchCappedSto.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import {
ModuleName,
BigNumber,
CappedSTOFundRaiseType,
SecurityTokenEvents_3_0_0,
SecurityTokenEvents,
} from '@polymathnetwork/contract-wrappers';
import { Procedure } from './Procedure';
import {
Expand Down Expand Up @@ -103,7 +103,7 @@ export class LaunchCappedSto extends Procedure<LaunchCappedStoProcedureArgs, Cap
const { logs } = receipt;

const [event] = findEvents({
eventName: SecurityTokenEvents_3_0_0.ModuleAdded,
eventName: SecurityTokenEvents.ModuleAdded,
logs,
});

Expand Down
4 changes: 2 additions & 2 deletions src/procedures/LaunchUsdTieredSto.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import {
ModuleName,
BigNumber,
FundRaiseType,
SecurityTokenEvents_3_0_0,
SecurityTokenEvents,
} from '@polymathnetwork/contract-wrappers';
import { Procedure } from './Procedure';
import {
Expand Down Expand Up @@ -129,7 +129,7 @@ export class LaunchUsdTieredSto extends Procedure<LaunchUsdTieredStoProcedureArg
const { logs } = receipt;

const [event] = findEvents({
eventName: SecurityTokenEvents_3_0_0.ModuleAdded,
eventName: SecurityTokenEvents.ModuleAdded,
logs,
});

Expand Down

0 comments on commit d70df68

Please sign in to comment.