AugurProject/augur-core

View on GitHub

Showing 833 of 833 total issues

Similar blocks of code found in 51 locations. Consider refactoring.
Open

        public approve_ = async(spender: string, value: BN, options?: { sender?: string }): Promise<boolean> => {
            options = options || {};
            const abi: AbiFunction = {"constant":false,"inputs":[{"name":"_spender","type":"address"},{"name":"_value","type":"uint256"}],"name":"approve","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"};
            const result = await this.localCall(abi, [spender, value], options.sender);
            return <boolean>result[0];
Severity: Major
Found in source/libraries/ContractInterfaces.ts and 50 other locations - About 7 hrs to fix
source/libraries/ContractInterfaces.ts on lines 498..503
source/libraries/ContractInterfaces.ts on lines 897..902
source/libraries/ContractInterfaces.ts on lines 981..986
source/libraries/ContractInterfaces.ts on lines 1030..1035
source/libraries/ContractInterfaces.ts on lines 1044..1049
source/libraries/ContractInterfaces.ts on lines 1093..1098
source/libraries/ContractInterfaces.ts on lines 1184..1189
source/libraries/ContractInterfaces.ts on lines 1198..1203
source/libraries/ContractInterfaces.ts on lines 1296..1301
source/libraries/ContractInterfaces.ts on lines 1324..1329
source/libraries/ContractInterfaces.ts on lines 1373..1378
source/libraries/ContractInterfaces.ts on lines 2241..2246
source/libraries/ContractInterfaces.ts on lines 2332..2337
source/libraries/ContractInterfaces.ts on lines 2374..2379
source/libraries/ContractInterfaces.ts on lines 2458..2463
source/libraries/ContractInterfaces.ts on lines 2514..2519
source/libraries/ContractInterfaces.ts on lines 2556..2561
source/libraries/ContractInterfaces.ts on lines 2570..2575
source/libraries/ContractInterfaces.ts on lines 2605..2610
source/libraries/ContractInterfaces.ts on lines 2640..2645
source/libraries/ContractInterfaces.ts on lines 2668..2673
source/libraries/ContractInterfaces.ts on lines 2752..2757
source/libraries/ContractInterfaces.ts on lines 2773..2778
source/libraries/ContractInterfaces.ts on lines 2864..2869
source/libraries/ContractInterfaces.ts on lines 2941..2946
source/libraries/ContractInterfaces.ts on lines 2962..2967
source/libraries/ContractInterfaces.ts on lines 3928..3933
source/libraries/ContractInterfaces.ts on lines 4005..4010
source/libraries/ContractInterfaces.ts on lines 4019..4024
source/libraries/ContractInterfaces.ts on lines 4117..4122
source/libraries/ContractInterfaces.ts on lines 4145..4150
source/libraries/ContractInterfaces.ts on lines 4194..4199
source/libraries/ContractInterfaces.ts on lines 4999..5004
source/libraries/ContractInterfaces.ts on lines 5020..5025
source/libraries/ContractInterfaces.ts on lines 5097..5102
source/libraries/ContractInterfaces.ts on lines 5153..5158
source/libraries/ContractInterfaces.ts on lines 5174..5179
source/libraries/ContractInterfaces.ts on lines 5202..5207
source/libraries/ContractInterfaces.ts on lines 5307..5312
source/libraries/ContractInterfaces.ts on lines 5342..5347
source/libraries/ContractInterfaces.ts on lines 5398..5403
source/libraries/ContractInterfaces.ts on lines 5552..5557
source/libraries/ContractInterfaces.ts on lines 5713..5718
source/libraries/ContractInterfaces.ts on lines 5853..5858
source/libraries/ContractInterfaces.ts on lines 5867..5872
source/libraries/ContractInterfaces.ts on lines 5937..5942
source/libraries/ContractInterfaces.ts on lines 6014..6019
source/libraries/ContractInterfaces.ts on lines 6035..6040
source/libraries/ContractInterfaces.ts on lines 6049..6054
source/libraries/ContractInterfaces.ts on lines 6063..6068

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 181.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 51 locations. Consider refactoring.
Open

        public increaseApproval_ = async(spender: string, addedValue: BN, options?: { sender?: string }): Promise<boolean> => {
            options = options || {};
            const abi: AbiFunction = {"constant":false,"inputs":[{"name":"_spender","type":"address"},{"name":"_addedValue","type":"uint256"}],"name":"increaseApproval","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"};
            const result = await this.localCall(abi, [spender, addedValue], options.sender);
            return <boolean>result[0];
Severity: Major
Found in source/libraries/ContractInterfaces.ts and 50 other locations - About 7 hrs to fix
source/libraries/ContractInterfaces.ts on lines 498..503
source/libraries/ContractInterfaces.ts on lines 897..902
source/libraries/ContractInterfaces.ts on lines 981..986
source/libraries/ContractInterfaces.ts on lines 1030..1035
source/libraries/ContractInterfaces.ts on lines 1044..1049
source/libraries/ContractInterfaces.ts on lines 1093..1098
source/libraries/ContractInterfaces.ts on lines 1184..1189
source/libraries/ContractInterfaces.ts on lines 1198..1203
source/libraries/ContractInterfaces.ts on lines 1296..1301
source/libraries/ContractInterfaces.ts on lines 1324..1329
source/libraries/ContractInterfaces.ts on lines 1373..1378
source/libraries/ContractInterfaces.ts on lines 2157..2162
source/libraries/ContractInterfaces.ts on lines 2241..2246
source/libraries/ContractInterfaces.ts on lines 2332..2337
source/libraries/ContractInterfaces.ts on lines 2374..2379
source/libraries/ContractInterfaces.ts on lines 2458..2463
source/libraries/ContractInterfaces.ts on lines 2514..2519
source/libraries/ContractInterfaces.ts on lines 2556..2561
source/libraries/ContractInterfaces.ts on lines 2570..2575
source/libraries/ContractInterfaces.ts on lines 2640..2645
source/libraries/ContractInterfaces.ts on lines 2668..2673
source/libraries/ContractInterfaces.ts on lines 2752..2757
source/libraries/ContractInterfaces.ts on lines 2773..2778
source/libraries/ContractInterfaces.ts on lines 2864..2869
source/libraries/ContractInterfaces.ts on lines 2941..2946
source/libraries/ContractInterfaces.ts on lines 2962..2967
source/libraries/ContractInterfaces.ts on lines 3928..3933
source/libraries/ContractInterfaces.ts on lines 4005..4010
source/libraries/ContractInterfaces.ts on lines 4019..4024
source/libraries/ContractInterfaces.ts on lines 4117..4122
source/libraries/ContractInterfaces.ts on lines 4145..4150
source/libraries/ContractInterfaces.ts on lines 4194..4199
source/libraries/ContractInterfaces.ts on lines 4999..5004
source/libraries/ContractInterfaces.ts on lines 5020..5025
source/libraries/ContractInterfaces.ts on lines 5097..5102
source/libraries/ContractInterfaces.ts on lines 5153..5158
source/libraries/ContractInterfaces.ts on lines 5174..5179
source/libraries/ContractInterfaces.ts on lines 5202..5207
source/libraries/ContractInterfaces.ts on lines 5307..5312
source/libraries/ContractInterfaces.ts on lines 5342..5347
source/libraries/ContractInterfaces.ts on lines 5398..5403
source/libraries/ContractInterfaces.ts on lines 5552..5557
source/libraries/ContractInterfaces.ts on lines 5713..5718
source/libraries/ContractInterfaces.ts on lines 5853..5858
source/libraries/ContractInterfaces.ts on lines 5867..5872
source/libraries/ContractInterfaces.ts on lines 5937..5942
source/libraries/ContractInterfaces.ts on lines 6014..6019
source/libraries/ContractInterfaces.ts on lines 6035..6040
source/libraries/ContractInterfaces.ts on lines 6049..6054
source/libraries/ContractInterfaces.ts on lines 6063..6068

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 181.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 51 locations. Consider refactoring.
Open

        public decreaseApproval_ = async(spender: string, subtractedValue: BN, options?: { sender?: string }): Promise<boolean> => {
            options = options || {};
            const abi: AbiFunction = {"constant":false,"inputs":[{"name":"_spender","type":"address"},{"name":"_subtractedValue","type":"uint256"}],"name":"decreaseApproval","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"};
            const result = await this.localCall(abi, [spender, subtractedValue], options.sender);
            return <boolean>result[0];
Severity: Major
Found in source/libraries/ContractInterfaces.ts and 50 other locations - About 7 hrs to fix
source/libraries/ContractInterfaces.ts on lines 498..503
source/libraries/ContractInterfaces.ts on lines 897..902
source/libraries/ContractInterfaces.ts on lines 981..986
source/libraries/ContractInterfaces.ts on lines 1030..1035
source/libraries/ContractInterfaces.ts on lines 1044..1049
source/libraries/ContractInterfaces.ts on lines 1093..1098
source/libraries/ContractInterfaces.ts on lines 1184..1189
source/libraries/ContractInterfaces.ts on lines 1198..1203
source/libraries/ContractInterfaces.ts on lines 1296..1301
source/libraries/ContractInterfaces.ts on lines 1324..1329
source/libraries/ContractInterfaces.ts on lines 1373..1378
source/libraries/ContractInterfaces.ts on lines 2157..2162
source/libraries/ContractInterfaces.ts on lines 2241..2246
source/libraries/ContractInterfaces.ts on lines 2332..2337
source/libraries/ContractInterfaces.ts on lines 2374..2379
source/libraries/ContractInterfaces.ts on lines 2458..2463
source/libraries/ContractInterfaces.ts on lines 2514..2519
source/libraries/ContractInterfaces.ts on lines 2556..2561
source/libraries/ContractInterfaces.ts on lines 2570..2575
source/libraries/ContractInterfaces.ts on lines 2605..2610
source/libraries/ContractInterfaces.ts on lines 2640..2645
source/libraries/ContractInterfaces.ts on lines 2668..2673
source/libraries/ContractInterfaces.ts on lines 2773..2778
source/libraries/ContractInterfaces.ts on lines 2864..2869
source/libraries/ContractInterfaces.ts on lines 2941..2946
source/libraries/ContractInterfaces.ts on lines 2962..2967
source/libraries/ContractInterfaces.ts on lines 3928..3933
source/libraries/ContractInterfaces.ts on lines 4005..4010
source/libraries/ContractInterfaces.ts on lines 4019..4024
source/libraries/ContractInterfaces.ts on lines 4117..4122
source/libraries/ContractInterfaces.ts on lines 4145..4150
source/libraries/ContractInterfaces.ts on lines 4194..4199
source/libraries/ContractInterfaces.ts on lines 4999..5004
source/libraries/ContractInterfaces.ts on lines 5020..5025
source/libraries/ContractInterfaces.ts on lines 5097..5102
source/libraries/ContractInterfaces.ts on lines 5153..5158
source/libraries/ContractInterfaces.ts on lines 5174..5179
source/libraries/ContractInterfaces.ts on lines 5202..5207
source/libraries/ContractInterfaces.ts on lines 5307..5312
source/libraries/ContractInterfaces.ts on lines 5342..5347
source/libraries/ContractInterfaces.ts on lines 5398..5403
source/libraries/ContractInterfaces.ts on lines 5552..5557
source/libraries/ContractInterfaces.ts on lines 5713..5718
source/libraries/ContractInterfaces.ts on lines 5853..5858
source/libraries/ContractInterfaces.ts on lines 5867..5872
source/libraries/ContractInterfaces.ts on lines 5937..5942
source/libraries/ContractInterfaces.ts on lines 6014..6019
source/libraries/ContractInterfaces.ts on lines 6035..6040
source/libraries/ContractInterfaces.ts on lines 6049..6054
source/libraries/ContractInterfaces.ts on lines 6063..6068

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 181.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 51 locations. Consider refactoring.
Open

        public decreaseApproval_ = async(spender: string, subtractedValue: BN, options?: { sender?: string }): Promise<boolean> => {
            options = options || {};
            const abi: AbiFunction = {"constant":false,"inputs":[{"name":"_spender","type":"address"},{"name":"_subtractedValue","type":"uint256"}],"name":"decreaseApproval","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"};
            const result = await this.localCall(abi, [spender, subtractedValue], options.sender);
            return <boolean>result[0];
Severity: Major
Found in source/libraries/ContractInterfaces.ts and 50 other locations - About 7 hrs to fix
source/libraries/ContractInterfaces.ts on lines 498..503
source/libraries/ContractInterfaces.ts on lines 897..902
source/libraries/ContractInterfaces.ts on lines 981..986
source/libraries/ContractInterfaces.ts on lines 1030..1035
source/libraries/ContractInterfaces.ts on lines 1044..1049
source/libraries/ContractInterfaces.ts on lines 1093..1098
source/libraries/ContractInterfaces.ts on lines 1184..1189
source/libraries/ContractInterfaces.ts on lines 1198..1203
source/libraries/ContractInterfaces.ts on lines 1296..1301
source/libraries/ContractInterfaces.ts on lines 1324..1329
source/libraries/ContractInterfaces.ts on lines 1373..1378
source/libraries/ContractInterfaces.ts on lines 2157..2162
source/libraries/ContractInterfaces.ts on lines 2332..2337
source/libraries/ContractInterfaces.ts on lines 2374..2379
source/libraries/ContractInterfaces.ts on lines 2458..2463
source/libraries/ContractInterfaces.ts on lines 2514..2519
source/libraries/ContractInterfaces.ts on lines 2556..2561
source/libraries/ContractInterfaces.ts on lines 2570..2575
source/libraries/ContractInterfaces.ts on lines 2605..2610
source/libraries/ContractInterfaces.ts on lines 2640..2645
source/libraries/ContractInterfaces.ts on lines 2668..2673
source/libraries/ContractInterfaces.ts on lines 2752..2757
source/libraries/ContractInterfaces.ts on lines 2773..2778
source/libraries/ContractInterfaces.ts on lines 2864..2869
source/libraries/ContractInterfaces.ts on lines 2941..2946
source/libraries/ContractInterfaces.ts on lines 2962..2967
source/libraries/ContractInterfaces.ts on lines 3928..3933
source/libraries/ContractInterfaces.ts on lines 4005..4010
source/libraries/ContractInterfaces.ts on lines 4019..4024
source/libraries/ContractInterfaces.ts on lines 4117..4122
source/libraries/ContractInterfaces.ts on lines 4145..4150
source/libraries/ContractInterfaces.ts on lines 4194..4199
source/libraries/ContractInterfaces.ts on lines 4999..5004
source/libraries/ContractInterfaces.ts on lines 5020..5025
source/libraries/ContractInterfaces.ts on lines 5097..5102
source/libraries/ContractInterfaces.ts on lines 5153..5158
source/libraries/ContractInterfaces.ts on lines 5174..5179
source/libraries/ContractInterfaces.ts on lines 5202..5207
source/libraries/ContractInterfaces.ts on lines 5307..5312
source/libraries/ContractInterfaces.ts on lines 5342..5347
source/libraries/ContractInterfaces.ts on lines 5398..5403
source/libraries/ContractInterfaces.ts on lines 5552..5557
source/libraries/ContractInterfaces.ts on lines 5713..5718
source/libraries/ContractInterfaces.ts on lines 5853..5858
source/libraries/ContractInterfaces.ts on lines 5867..5872
source/libraries/ContractInterfaces.ts on lines 5937..5942
source/libraries/ContractInterfaces.ts on lines 6014..6019
source/libraries/ContractInterfaces.ts on lines 6035..6040
source/libraries/ContractInterfaces.ts on lines 6049..6054
source/libraries/ContractInterfaces.ts on lines 6063..6068

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 181.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 51 locations. Consider refactoring.
Open

        public approve_ = async(spender: string, value: BN, options?: { sender?: string }): Promise<boolean> => {
            options = options || {};
            const abi: AbiFunction = {"constant":false,"inputs":[{"name":"_spender","type":"address"},{"name":"_value","type":"uint256"}],"name":"approve","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"};
            const result = await this.localCall(abi, [spender, value], options.sender);
            return <boolean>result[0];
Severity: Major
Found in source/libraries/ContractInterfaces.ts and 50 other locations - About 7 hrs to fix
source/libraries/ContractInterfaces.ts on lines 498..503
source/libraries/ContractInterfaces.ts on lines 897..902
source/libraries/ContractInterfaces.ts on lines 981..986
source/libraries/ContractInterfaces.ts on lines 1030..1035
source/libraries/ContractInterfaces.ts on lines 1044..1049
source/libraries/ContractInterfaces.ts on lines 1093..1098
source/libraries/ContractInterfaces.ts on lines 1184..1189
source/libraries/ContractInterfaces.ts on lines 1198..1203
source/libraries/ContractInterfaces.ts on lines 1296..1301
source/libraries/ContractInterfaces.ts on lines 1324..1329
source/libraries/ContractInterfaces.ts on lines 1373..1378
source/libraries/ContractInterfaces.ts on lines 2157..2162
source/libraries/ContractInterfaces.ts on lines 2241..2246
source/libraries/ContractInterfaces.ts on lines 2332..2337
source/libraries/ContractInterfaces.ts on lines 2374..2379
source/libraries/ContractInterfaces.ts on lines 2458..2463
source/libraries/ContractInterfaces.ts on lines 2514..2519
source/libraries/ContractInterfaces.ts on lines 2556..2561
source/libraries/ContractInterfaces.ts on lines 2570..2575
source/libraries/ContractInterfaces.ts on lines 2605..2610
source/libraries/ContractInterfaces.ts on lines 2640..2645
source/libraries/ContractInterfaces.ts on lines 2668..2673
source/libraries/ContractInterfaces.ts on lines 2752..2757
source/libraries/ContractInterfaces.ts on lines 2773..2778
source/libraries/ContractInterfaces.ts on lines 2864..2869
source/libraries/ContractInterfaces.ts on lines 2941..2946
source/libraries/ContractInterfaces.ts on lines 2962..2967
source/libraries/ContractInterfaces.ts on lines 4005..4010
source/libraries/ContractInterfaces.ts on lines 4019..4024
source/libraries/ContractInterfaces.ts on lines 4117..4122
source/libraries/ContractInterfaces.ts on lines 4145..4150
source/libraries/ContractInterfaces.ts on lines 4194..4199
source/libraries/ContractInterfaces.ts on lines 4999..5004
source/libraries/ContractInterfaces.ts on lines 5020..5025
source/libraries/ContractInterfaces.ts on lines 5097..5102
source/libraries/ContractInterfaces.ts on lines 5153..5158
source/libraries/ContractInterfaces.ts on lines 5174..5179
source/libraries/ContractInterfaces.ts on lines 5202..5207
source/libraries/ContractInterfaces.ts on lines 5307..5312
source/libraries/ContractInterfaces.ts on lines 5342..5347
source/libraries/ContractInterfaces.ts on lines 5398..5403
source/libraries/ContractInterfaces.ts on lines 5552..5557
source/libraries/ContractInterfaces.ts on lines 5713..5718
source/libraries/ContractInterfaces.ts on lines 5853..5858
source/libraries/ContractInterfaces.ts on lines 5867..5872
source/libraries/ContractInterfaces.ts on lines 5937..5942
source/libraries/ContractInterfaces.ts on lines 6014..6019
source/libraries/ContractInterfaces.ts on lines 6035..6040
source/libraries/ContractInterfaces.ts on lines 6049..6054
source/libraries/ContractInterfaces.ts on lines 6063..6068

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 181.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 51 locations. Consider refactoring.
Open

        public approve_ = async(spender: string, value: BN, options?: { sender?: string }): Promise<boolean> => {
            options = options || {};
            const abi: AbiFunction = {"constant":false,"inputs":[{"name":"_spender","type":"address"},{"name":"_value","type":"uint256"}],"name":"approve","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"};
            const result = await this.localCall(abi, [spender, value], options.sender);
            return <boolean>result[0];
Severity: Major
Found in source/libraries/ContractInterfaces.ts and 50 other locations - About 7 hrs to fix
source/libraries/ContractInterfaces.ts on lines 498..503
source/libraries/ContractInterfaces.ts on lines 897..902
source/libraries/ContractInterfaces.ts on lines 981..986
source/libraries/ContractInterfaces.ts on lines 1030..1035
source/libraries/ContractInterfaces.ts on lines 1044..1049
source/libraries/ContractInterfaces.ts on lines 1093..1098
source/libraries/ContractInterfaces.ts on lines 1184..1189
source/libraries/ContractInterfaces.ts on lines 1198..1203
source/libraries/ContractInterfaces.ts on lines 1296..1301
source/libraries/ContractInterfaces.ts on lines 1324..1329
source/libraries/ContractInterfaces.ts on lines 1373..1378
source/libraries/ContractInterfaces.ts on lines 2157..2162
source/libraries/ContractInterfaces.ts on lines 2241..2246
source/libraries/ContractInterfaces.ts on lines 2332..2337
source/libraries/ContractInterfaces.ts on lines 2374..2379
source/libraries/ContractInterfaces.ts on lines 2514..2519
source/libraries/ContractInterfaces.ts on lines 2556..2561
source/libraries/ContractInterfaces.ts on lines 2570..2575
source/libraries/ContractInterfaces.ts on lines 2605..2610
source/libraries/ContractInterfaces.ts on lines 2640..2645
source/libraries/ContractInterfaces.ts on lines 2668..2673
source/libraries/ContractInterfaces.ts on lines 2752..2757
source/libraries/ContractInterfaces.ts on lines 2773..2778
source/libraries/ContractInterfaces.ts on lines 2864..2869
source/libraries/ContractInterfaces.ts on lines 2941..2946
source/libraries/ContractInterfaces.ts on lines 2962..2967
source/libraries/ContractInterfaces.ts on lines 3928..3933
source/libraries/ContractInterfaces.ts on lines 4005..4010
source/libraries/ContractInterfaces.ts on lines 4019..4024
source/libraries/ContractInterfaces.ts on lines 4117..4122
source/libraries/ContractInterfaces.ts on lines 4145..4150
source/libraries/ContractInterfaces.ts on lines 4194..4199
source/libraries/ContractInterfaces.ts on lines 4999..5004
source/libraries/ContractInterfaces.ts on lines 5020..5025
source/libraries/ContractInterfaces.ts on lines 5097..5102
source/libraries/ContractInterfaces.ts on lines 5153..5158
source/libraries/ContractInterfaces.ts on lines 5174..5179
source/libraries/ContractInterfaces.ts on lines 5202..5207
source/libraries/ContractInterfaces.ts on lines 5307..5312
source/libraries/ContractInterfaces.ts on lines 5342..5347
source/libraries/ContractInterfaces.ts on lines 5398..5403
source/libraries/ContractInterfaces.ts on lines 5552..5557
source/libraries/ContractInterfaces.ts on lines 5713..5718
source/libraries/ContractInterfaces.ts on lines 5853..5858
source/libraries/ContractInterfaces.ts on lines 5867..5872
source/libraries/ContractInterfaces.ts on lines 5937..5942
source/libraries/ContractInterfaces.ts on lines 6014..6019
source/libraries/ContractInterfaces.ts on lines 6035..6040
source/libraries/ContractInterfaces.ts on lines 6049..6054
source/libraries/ContractInterfaces.ts on lines 6063..6068

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 181.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 51 locations. Consider refactoring.
Open

        public decreaseApproval_ = async(spender: string, subtractedValue: BN, options?: { sender?: string }): Promise<boolean> => {
            options = options || {};
            const abi: AbiFunction = {"constant":false,"inputs":[{"name":"_spender","type":"address"},{"name":"_subtractedValue","type":"uint256"}],"name":"decreaseApproval","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"};
            const result = await this.localCall(abi, [spender, subtractedValue], options.sender);
            return <boolean>result[0];
Severity: Major
Found in source/libraries/ContractInterfaces.ts and 50 other locations - About 7 hrs to fix
source/libraries/ContractInterfaces.ts on lines 498..503
source/libraries/ContractInterfaces.ts on lines 897..902
source/libraries/ContractInterfaces.ts on lines 981..986
source/libraries/ContractInterfaces.ts on lines 1030..1035
source/libraries/ContractInterfaces.ts on lines 1044..1049
source/libraries/ContractInterfaces.ts on lines 1093..1098
source/libraries/ContractInterfaces.ts on lines 1184..1189
source/libraries/ContractInterfaces.ts on lines 1198..1203
source/libraries/ContractInterfaces.ts on lines 1296..1301
source/libraries/ContractInterfaces.ts on lines 1324..1329
source/libraries/ContractInterfaces.ts on lines 1373..1378
source/libraries/ContractInterfaces.ts on lines 2157..2162
source/libraries/ContractInterfaces.ts on lines 2241..2246
source/libraries/ContractInterfaces.ts on lines 2332..2337
source/libraries/ContractInterfaces.ts on lines 2374..2379
source/libraries/ContractInterfaces.ts on lines 2458..2463
source/libraries/ContractInterfaces.ts on lines 2556..2561
source/libraries/ContractInterfaces.ts on lines 2570..2575
source/libraries/ContractInterfaces.ts on lines 2605..2610
source/libraries/ContractInterfaces.ts on lines 2640..2645
source/libraries/ContractInterfaces.ts on lines 2668..2673
source/libraries/ContractInterfaces.ts on lines 2752..2757
source/libraries/ContractInterfaces.ts on lines 2773..2778
source/libraries/ContractInterfaces.ts on lines 2864..2869
source/libraries/ContractInterfaces.ts on lines 2941..2946
source/libraries/ContractInterfaces.ts on lines 2962..2967
source/libraries/ContractInterfaces.ts on lines 3928..3933
source/libraries/ContractInterfaces.ts on lines 4005..4010
source/libraries/ContractInterfaces.ts on lines 4019..4024
source/libraries/ContractInterfaces.ts on lines 4117..4122
source/libraries/ContractInterfaces.ts on lines 4145..4150
source/libraries/ContractInterfaces.ts on lines 4194..4199
source/libraries/ContractInterfaces.ts on lines 4999..5004
source/libraries/ContractInterfaces.ts on lines 5020..5025
source/libraries/ContractInterfaces.ts on lines 5097..5102
source/libraries/ContractInterfaces.ts on lines 5153..5158
source/libraries/ContractInterfaces.ts on lines 5174..5179
source/libraries/ContractInterfaces.ts on lines 5202..5207
source/libraries/ContractInterfaces.ts on lines 5307..5312
source/libraries/ContractInterfaces.ts on lines 5342..5347
source/libraries/ContractInterfaces.ts on lines 5398..5403
source/libraries/ContractInterfaces.ts on lines 5552..5557
source/libraries/ContractInterfaces.ts on lines 5713..5718
source/libraries/ContractInterfaces.ts on lines 5853..5858
source/libraries/ContractInterfaces.ts on lines 5867..5872
source/libraries/ContractInterfaces.ts on lines 5937..5942
source/libraries/ContractInterfaces.ts on lines 6014..6019
source/libraries/ContractInterfaces.ts on lines 6035..6040
source/libraries/ContractInterfaces.ts on lines 6049..6054
source/libraries/ContractInterfaces.ts on lines 6063..6068

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 181.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 51 locations. Consider refactoring.
Open

        public logFeeWindowCreated_ = async(feeWindow: string, id: BN, options?: { sender?: string }): Promise<boolean> => {
            options = options || {};
            const abi: AbiFunction = {"constant":false,"inputs":[{"name":"_feeWindow","type":"address"},{"name":"_id","type":"uint256"}],"name":"logFeeWindowCreated","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"};
            const result = await this.localCall(abi, [feeWindow, id], options.sender);
            return <boolean>result[0];
Severity: Major
Found in source/libraries/ContractInterfaces.ts and 50 other locations - About 7 hrs to fix
source/libraries/ContractInterfaces.ts on lines 897..902
source/libraries/ContractInterfaces.ts on lines 981..986
source/libraries/ContractInterfaces.ts on lines 1030..1035
source/libraries/ContractInterfaces.ts on lines 1044..1049
source/libraries/ContractInterfaces.ts on lines 1093..1098
source/libraries/ContractInterfaces.ts on lines 1184..1189
source/libraries/ContractInterfaces.ts on lines 1198..1203
source/libraries/ContractInterfaces.ts on lines 1296..1301
source/libraries/ContractInterfaces.ts on lines 1324..1329
source/libraries/ContractInterfaces.ts on lines 1373..1378
source/libraries/ContractInterfaces.ts on lines 2157..2162
source/libraries/ContractInterfaces.ts on lines 2241..2246
source/libraries/ContractInterfaces.ts on lines 2332..2337
source/libraries/ContractInterfaces.ts on lines 2374..2379
source/libraries/ContractInterfaces.ts on lines 2458..2463
source/libraries/ContractInterfaces.ts on lines 2514..2519
source/libraries/ContractInterfaces.ts on lines 2556..2561
source/libraries/ContractInterfaces.ts on lines 2570..2575
source/libraries/ContractInterfaces.ts on lines 2605..2610
source/libraries/ContractInterfaces.ts on lines 2640..2645
source/libraries/ContractInterfaces.ts on lines 2668..2673
source/libraries/ContractInterfaces.ts on lines 2752..2757
source/libraries/ContractInterfaces.ts on lines 2773..2778
source/libraries/ContractInterfaces.ts on lines 2864..2869
source/libraries/ContractInterfaces.ts on lines 2941..2946
source/libraries/ContractInterfaces.ts on lines 2962..2967
source/libraries/ContractInterfaces.ts on lines 3928..3933
source/libraries/ContractInterfaces.ts on lines 4005..4010
source/libraries/ContractInterfaces.ts on lines 4019..4024
source/libraries/ContractInterfaces.ts on lines 4117..4122
source/libraries/ContractInterfaces.ts on lines 4145..4150
source/libraries/ContractInterfaces.ts on lines 4194..4199
source/libraries/ContractInterfaces.ts on lines 4999..5004
source/libraries/ContractInterfaces.ts on lines 5020..5025
source/libraries/ContractInterfaces.ts on lines 5097..5102
source/libraries/ContractInterfaces.ts on lines 5153..5158
source/libraries/ContractInterfaces.ts on lines 5174..5179
source/libraries/ContractInterfaces.ts on lines 5202..5207
source/libraries/ContractInterfaces.ts on lines 5307..5312
source/libraries/ContractInterfaces.ts on lines 5342..5347
source/libraries/ContractInterfaces.ts on lines 5398..5403
source/libraries/ContractInterfaces.ts on lines 5552..5557
source/libraries/ContractInterfaces.ts on lines 5713..5718
source/libraries/ContractInterfaces.ts on lines 5853..5858
source/libraries/ContractInterfaces.ts on lines 5867..5872
source/libraries/ContractInterfaces.ts on lines 5937..5942
source/libraries/ContractInterfaces.ts on lines 6014..6019
source/libraries/ContractInterfaces.ts on lines 6035..6040
source/libraries/ContractInterfaces.ts on lines 6049..6054
source/libraries/ContractInterfaces.ts on lines 6063..6068

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 181.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 51 locations. Consider refactoring.
Open

        public transfer_ = async(to: string, value: BN, options?: { sender?: string }): Promise<boolean> => {
            options = options || {};
            const abi: AbiFunction = {"constant":false,"inputs":[{"name":"_to","type":"address"},{"name":"_value","type":"uint256"}],"name":"transfer","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"};
            const result = await this.localCall(abi, [to, value], options.sender);
            return <boolean>result[0];
Severity: Major
Found in source/libraries/ContractInterfaces.ts and 50 other locations - About 7 hrs to fix
source/libraries/ContractInterfaces.ts on lines 498..503
source/libraries/ContractInterfaces.ts on lines 897..902
source/libraries/ContractInterfaces.ts on lines 981..986
source/libraries/ContractInterfaces.ts on lines 1044..1049
source/libraries/ContractInterfaces.ts on lines 1093..1098
source/libraries/ContractInterfaces.ts on lines 1184..1189
source/libraries/ContractInterfaces.ts on lines 1198..1203
source/libraries/ContractInterfaces.ts on lines 1296..1301
source/libraries/ContractInterfaces.ts on lines 1324..1329
source/libraries/ContractInterfaces.ts on lines 1373..1378
source/libraries/ContractInterfaces.ts on lines 2157..2162
source/libraries/ContractInterfaces.ts on lines 2241..2246
source/libraries/ContractInterfaces.ts on lines 2332..2337
source/libraries/ContractInterfaces.ts on lines 2374..2379
source/libraries/ContractInterfaces.ts on lines 2458..2463
source/libraries/ContractInterfaces.ts on lines 2514..2519
source/libraries/ContractInterfaces.ts on lines 2556..2561
source/libraries/ContractInterfaces.ts on lines 2570..2575
source/libraries/ContractInterfaces.ts on lines 2605..2610
source/libraries/ContractInterfaces.ts on lines 2640..2645
source/libraries/ContractInterfaces.ts on lines 2668..2673
source/libraries/ContractInterfaces.ts on lines 2752..2757
source/libraries/ContractInterfaces.ts on lines 2773..2778
source/libraries/ContractInterfaces.ts on lines 2864..2869
source/libraries/ContractInterfaces.ts on lines 2941..2946
source/libraries/ContractInterfaces.ts on lines 2962..2967
source/libraries/ContractInterfaces.ts on lines 3928..3933
source/libraries/ContractInterfaces.ts on lines 4005..4010
source/libraries/ContractInterfaces.ts on lines 4019..4024
source/libraries/ContractInterfaces.ts on lines 4117..4122
source/libraries/ContractInterfaces.ts on lines 4145..4150
source/libraries/ContractInterfaces.ts on lines 4194..4199
source/libraries/ContractInterfaces.ts on lines 4999..5004
source/libraries/ContractInterfaces.ts on lines 5020..5025
source/libraries/ContractInterfaces.ts on lines 5097..5102
source/libraries/ContractInterfaces.ts on lines 5153..5158
source/libraries/ContractInterfaces.ts on lines 5174..5179
source/libraries/ContractInterfaces.ts on lines 5202..5207
source/libraries/ContractInterfaces.ts on lines 5307..5312
source/libraries/ContractInterfaces.ts on lines 5342..5347
source/libraries/ContractInterfaces.ts on lines 5398..5403
source/libraries/ContractInterfaces.ts on lines 5552..5557
source/libraries/ContractInterfaces.ts on lines 5713..5718
source/libraries/ContractInterfaces.ts on lines 5853..5858
source/libraries/ContractInterfaces.ts on lines 5867..5872
source/libraries/ContractInterfaces.ts on lines 5937..5942
source/libraries/ContractInterfaces.ts on lines 6014..6019
source/libraries/ContractInterfaces.ts on lines 6035..6040
source/libraries/ContractInterfaces.ts on lines 6049..6054
source/libraries/ContractInterfaces.ts on lines 6063..6068

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 181.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 51 locations. Consider refactoring.
Open

        public migrateOut_ = async(destination: string, attotokens: BN, options?: { sender?: string }): Promise<boolean> => {
            options = options || {};
            const abi: AbiFunction = {"constant":false,"inputs":[{"name":"_destination","type":"address"},{"name":"_attotokens","type":"uint256"}],"name":"migrateOut","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"};
            const result = await this.localCall(abi, [destination, attotokens], options.sender);
            return <boolean>result[0];
Severity: Major
Found in source/libraries/ContractInterfaces.ts and 50 other locations - About 7 hrs to fix
source/libraries/ContractInterfaces.ts on lines 498..503
source/libraries/ContractInterfaces.ts on lines 897..902
source/libraries/ContractInterfaces.ts on lines 981..986
source/libraries/ContractInterfaces.ts on lines 1030..1035
source/libraries/ContractInterfaces.ts on lines 1044..1049
source/libraries/ContractInterfaces.ts on lines 1093..1098
source/libraries/ContractInterfaces.ts on lines 1184..1189
source/libraries/ContractInterfaces.ts on lines 1296..1301
source/libraries/ContractInterfaces.ts on lines 1324..1329
source/libraries/ContractInterfaces.ts on lines 1373..1378
source/libraries/ContractInterfaces.ts on lines 2157..2162
source/libraries/ContractInterfaces.ts on lines 2241..2246
source/libraries/ContractInterfaces.ts on lines 2332..2337
source/libraries/ContractInterfaces.ts on lines 2374..2379
source/libraries/ContractInterfaces.ts on lines 2458..2463
source/libraries/ContractInterfaces.ts on lines 2514..2519
source/libraries/ContractInterfaces.ts on lines 2556..2561
source/libraries/ContractInterfaces.ts on lines 2570..2575
source/libraries/ContractInterfaces.ts on lines 2605..2610
source/libraries/ContractInterfaces.ts on lines 2640..2645
source/libraries/ContractInterfaces.ts on lines 2668..2673
source/libraries/ContractInterfaces.ts on lines 2752..2757
source/libraries/ContractInterfaces.ts on lines 2773..2778
source/libraries/ContractInterfaces.ts on lines 2864..2869
source/libraries/ContractInterfaces.ts on lines 2941..2946
source/libraries/ContractInterfaces.ts on lines 2962..2967
source/libraries/ContractInterfaces.ts on lines 3928..3933
source/libraries/ContractInterfaces.ts on lines 4005..4010
source/libraries/ContractInterfaces.ts on lines 4019..4024
source/libraries/ContractInterfaces.ts on lines 4117..4122
source/libraries/ContractInterfaces.ts on lines 4145..4150
source/libraries/ContractInterfaces.ts on lines 4194..4199
source/libraries/ContractInterfaces.ts on lines 4999..5004
source/libraries/ContractInterfaces.ts on lines 5020..5025
source/libraries/ContractInterfaces.ts on lines 5097..5102
source/libraries/ContractInterfaces.ts on lines 5153..5158
source/libraries/ContractInterfaces.ts on lines 5174..5179
source/libraries/ContractInterfaces.ts on lines 5202..5207
source/libraries/ContractInterfaces.ts on lines 5307..5312
source/libraries/ContractInterfaces.ts on lines 5342..5347
source/libraries/ContractInterfaces.ts on lines 5398..5403
source/libraries/ContractInterfaces.ts on lines 5552..5557
source/libraries/ContractInterfaces.ts on lines 5713..5718
source/libraries/ContractInterfaces.ts on lines 5853..5858
source/libraries/ContractInterfaces.ts on lines 5867..5872
source/libraries/ContractInterfaces.ts on lines 5937..5942
source/libraries/ContractInterfaces.ts on lines 6014..6019
source/libraries/ContractInterfaces.ts on lines 6035..6040
source/libraries/ContractInterfaces.ts on lines 6049..6054
source/libraries/ContractInterfaces.ts on lines 6063..6068

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 181.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 51 locations. Consider refactoring.
Open

        public trustedUniverseBuy_ = async(buyer: string, attotokens: BN, options?: { sender?: string }): Promise<boolean> => {
            options = options || {};
            const abi: AbiFunction = {"constant":false,"inputs":[{"name":"_buyer","type":"address"},{"name":"_attotokens","type":"uint256"}],"name":"trustedUniverseBuy","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"};
            const result = await this.localCall(abi, [buyer, attotokens], options.sender);
            return <boolean>result[0];
Severity: Major
Found in source/libraries/ContractInterfaces.ts and 50 other locations - About 7 hrs to fix
source/libraries/ContractInterfaces.ts on lines 498..503
source/libraries/ContractInterfaces.ts on lines 897..902
source/libraries/ContractInterfaces.ts on lines 981..986
source/libraries/ContractInterfaces.ts on lines 1030..1035
source/libraries/ContractInterfaces.ts on lines 1044..1049
source/libraries/ContractInterfaces.ts on lines 1093..1098
source/libraries/ContractInterfaces.ts on lines 1184..1189
source/libraries/ContractInterfaces.ts on lines 1198..1203
source/libraries/ContractInterfaces.ts on lines 1296..1301
source/libraries/ContractInterfaces.ts on lines 1324..1329
source/libraries/ContractInterfaces.ts on lines 1373..1378
source/libraries/ContractInterfaces.ts on lines 2157..2162
source/libraries/ContractInterfaces.ts on lines 2241..2246
source/libraries/ContractInterfaces.ts on lines 2332..2337
source/libraries/ContractInterfaces.ts on lines 2374..2379
source/libraries/ContractInterfaces.ts on lines 2458..2463
source/libraries/ContractInterfaces.ts on lines 2514..2519
source/libraries/ContractInterfaces.ts on lines 2556..2561
source/libraries/ContractInterfaces.ts on lines 2570..2575
source/libraries/ContractInterfaces.ts on lines 2605..2610
source/libraries/ContractInterfaces.ts on lines 2640..2645
source/libraries/ContractInterfaces.ts on lines 2668..2673
source/libraries/ContractInterfaces.ts on lines 2752..2757
source/libraries/ContractInterfaces.ts on lines 2864..2869
source/libraries/ContractInterfaces.ts on lines 2941..2946
source/libraries/ContractInterfaces.ts on lines 2962..2967
source/libraries/ContractInterfaces.ts on lines 3928..3933
source/libraries/ContractInterfaces.ts on lines 4005..4010
source/libraries/ContractInterfaces.ts on lines 4019..4024
source/libraries/ContractInterfaces.ts on lines 4117..4122
source/libraries/ContractInterfaces.ts on lines 4145..4150
source/libraries/ContractInterfaces.ts on lines 4194..4199
source/libraries/ContractInterfaces.ts on lines 4999..5004
source/libraries/ContractInterfaces.ts on lines 5020..5025
source/libraries/ContractInterfaces.ts on lines 5097..5102
source/libraries/ContractInterfaces.ts on lines 5153..5158
source/libraries/ContractInterfaces.ts on lines 5174..5179
source/libraries/ContractInterfaces.ts on lines 5202..5207
source/libraries/ContractInterfaces.ts on lines 5307..5312
source/libraries/ContractInterfaces.ts on lines 5342..5347
source/libraries/ContractInterfaces.ts on lines 5398..5403
source/libraries/ContractInterfaces.ts on lines 5552..5557
source/libraries/ContractInterfaces.ts on lines 5713..5718
source/libraries/ContractInterfaces.ts on lines 5853..5858
source/libraries/ContractInterfaces.ts on lines 5867..5872
source/libraries/ContractInterfaces.ts on lines 5937..5942
source/libraries/ContractInterfaces.ts on lines 6014..6019
source/libraries/ContractInterfaces.ts on lines 6035..6040
source/libraries/ContractInterfaces.ts on lines 6049..6054
source/libraries/ContractInterfaces.ts on lines 6063..6068

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 181.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 51 locations. Consider refactoring.
Open

        public migrateOut_ = async(destination: string, attotokens: BN, options?: { sender?: string }): Promise<boolean> => {
            options = options || {};
            const abi: AbiFunction = {"constant":false,"inputs":[{"name":"_destination","type":"address"},{"name":"_attotokens","type":"uint256"}],"name":"migrateOut","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"};
            const result = await this.localCall(abi, [destination, attotokens], options.sender);
            return <boolean>result[0];
Severity: Major
Found in source/libraries/ContractInterfaces.ts and 50 other locations - About 7 hrs to fix
source/libraries/ContractInterfaces.ts on lines 498..503
source/libraries/ContractInterfaces.ts on lines 897..902
source/libraries/ContractInterfaces.ts on lines 981..986
source/libraries/ContractInterfaces.ts on lines 1030..1035
source/libraries/ContractInterfaces.ts on lines 1044..1049
source/libraries/ContractInterfaces.ts on lines 1093..1098
source/libraries/ContractInterfaces.ts on lines 1184..1189
source/libraries/ContractInterfaces.ts on lines 1198..1203
source/libraries/ContractInterfaces.ts on lines 1296..1301
source/libraries/ContractInterfaces.ts on lines 1324..1329
source/libraries/ContractInterfaces.ts on lines 1373..1378
source/libraries/ContractInterfaces.ts on lines 2157..2162
source/libraries/ContractInterfaces.ts on lines 2241..2246
source/libraries/ContractInterfaces.ts on lines 2332..2337
source/libraries/ContractInterfaces.ts on lines 2374..2379
source/libraries/ContractInterfaces.ts on lines 2458..2463
source/libraries/ContractInterfaces.ts on lines 2514..2519
source/libraries/ContractInterfaces.ts on lines 2556..2561
source/libraries/ContractInterfaces.ts on lines 2570..2575
source/libraries/ContractInterfaces.ts on lines 2605..2610
source/libraries/ContractInterfaces.ts on lines 2640..2645
source/libraries/ContractInterfaces.ts on lines 2668..2673
source/libraries/ContractInterfaces.ts on lines 2752..2757
source/libraries/ContractInterfaces.ts on lines 2773..2778
source/libraries/ContractInterfaces.ts on lines 2864..2869
source/libraries/ContractInterfaces.ts on lines 2941..2946
source/libraries/ContractInterfaces.ts on lines 2962..2967
source/libraries/ContractInterfaces.ts on lines 3928..3933
source/libraries/ContractInterfaces.ts on lines 4005..4010
source/libraries/ContractInterfaces.ts on lines 4117..4122
source/libraries/ContractInterfaces.ts on lines 4145..4150
source/libraries/ContractInterfaces.ts on lines 4194..4199
source/libraries/ContractInterfaces.ts on lines 4999..5004
source/libraries/ContractInterfaces.ts on lines 5020..5025
source/libraries/ContractInterfaces.ts on lines 5097..5102
source/libraries/ContractInterfaces.ts on lines 5153..5158
source/libraries/ContractInterfaces.ts on lines 5174..5179
source/libraries/ContractInterfaces.ts on lines 5202..5207
source/libraries/ContractInterfaces.ts on lines 5307..5312
source/libraries/ContractInterfaces.ts on lines 5342..5347
source/libraries/ContractInterfaces.ts on lines 5398..5403
source/libraries/ContractInterfaces.ts on lines 5552..5557
source/libraries/ContractInterfaces.ts on lines 5713..5718
source/libraries/ContractInterfaces.ts on lines 5853..5858
source/libraries/ContractInterfaces.ts on lines 5867..5872
source/libraries/ContractInterfaces.ts on lines 5937..5942
source/libraries/ContractInterfaces.ts on lines 6014..6019
source/libraries/ContractInterfaces.ts on lines 6035..6040
source/libraries/ContractInterfaces.ts on lines 6049..6054
source/libraries/ContractInterfaces.ts on lines 6063..6068

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 181.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 51 locations. Consider refactoring.
Open

        public decreaseApproval_ = async(spender: string, subtractedValue: BN, options?: { sender?: string }): Promise<boolean> => {
            options = options || {};
            const abi: AbiFunction = {"constant":false,"inputs":[{"name":"_spender","type":"address"},{"name":"_subtractedValue","type":"uint256"}],"name":"decreaseApproval","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"};
            const result = await this.localCall(abi, [spender, subtractedValue], options.sender);
            return <boolean>result[0];
Severity: Major
Found in source/libraries/ContractInterfaces.ts and 50 other locations - About 7 hrs to fix
source/libraries/ContractInterfaces.ts on lines 498..503
source/libraries/ContractInterfaces.ts on lines 897..902
source/libraries/ContractInterfaces.ts on lines 981..986
source/libraries/ContractInterfaces.ts on lines 1030..1035
source/libraries/ContractInterfaces.ts on lines 1044..1049
source/libraries/ContractInterfaces.ts on lines 1093..1098
source/libraries/ContractInterfaces.ts on lines 1184..1189
source/libraries/ContractInterfaces.ts on lines 1198..1203
source/libraries/ContractInterfaces.ts on lines 1296..1301
source/libraries/ContractInterfaces.ts on lines 1324..1329
source/libraries/ContractInterfaces.ts on lines 1373..1378
source/libraries/ContractInterfaces.ts on lines 2157..2162
source/libraries/ContractInterfaces.ts on lines 2241..2246
source/libraries/ContractInterfaces.ts on lines 2332..2337
source/libraries/ContractInterfaces.ts on lines 2374..2379
source/libraries/ContractInterfaces.ts on lines 2458..2463
source/libraries/ContractInterfaces.ts on lines 2514..2519
source/libraries/ContractInterfaces.ts on lines 2556..2561
source/libraries/ContractInterfaces.ts on lines 2570..2575
source/libraries/ContractInterfaces.ts on lines 2605..2610
source/libraries/ContractInterfaces.ts on lines 2640..2645
source/libraries/ContractInterfaces.ts on lines 2668..2673
source/libraries/ContractInterfaces.ts on lines 2752..2757
source/libraries/ContractInterfaces.ts on lines 2773..2778
source/libraries/ContractInterfaces.ts on lines 2864..2869
source/libraries/ContractInterfaces.ts on lines 2941..2946
source/libraries/ContractInterfaces.ts on lines 2962..2967
source/libraries/ContractInterfaces.ts on lines 3928..3933
source/libraries/ContractInterfaces.ts on lines 4005..4010
source/libraries/ContractInterfaces.ts on lines 4019..4024
source/libraries/ContractInterfaces.ts on lines 4117..4122
source/libraries/ContractInterfaces.ts on lines 4145..4150
source/libraries/ContractInterfaces.ts on lines 4194..4199
source/libraries/ContractInterfaces.ts on lines 4999..5004
source/libraries/ContractInterfaces.ts on lines 5020..5025
source/libraries/ContractInterfaces.ts on lines 5153..5158
source/libraries/ContractInterfaces.ts on lines 5174..5179
source/libraries/ContractInterfaces.ts on lines 5202..5207
source/libraries/ContractInterfaces.ts on lines 5307..5312
source/libraries/ContractInterfaces.ts on lines 5342..5347
source/libraries/ContractInterfaces.ts on lines 5398..5403
source/libraries/ContractInterfaces.ts on lines 5552..5557
source/libraries/ContractInterfaces.ts on lines 5713..5718
source/libraries/ContractInterfaces.ts on lines 5853..5858
source/libraries/ContractInterfaces.ts on lines 5867..5872
source/libraries/ContractInterfaces.ts on lines 5937..5942
source/libraries/ContractInterfaces.ts on lines 6014..6019
source/libraries/ContractInterfaces.ts on lines 6035..6040
source/libraries/ContractInterfaces.ts on lines 6049..6054
source/libraries/ContractInterfaces.ts on lines 6063..6068

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 181.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 51 locations. Consider refactoring.
Open

        public transfer_ = async(to: string, value: BN, options?: { sender?: string }): Promise<boolean> => {
            options = options || {};
            const abi: AbiFunction = {"constant":false,"inputs":[{"name":"_to","type":"address"},{"name":"_value","type":"uint256"}],"name":"transfer","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"};
            const result = await this.localCall(abi, [to, value], options.sender);
            return <boolean>result[0];
Severity: Major
Found in source/libraries/ContractInterfaces.ts and 50 other locations - About 7 hrs to fix
source/libraries/ContractInterfaces.ts on lines 498..503
source/libraries/ContractInterfaces.ts on lines 897..902
source/libraries/ContractInterfaces.ts on lines 981..986
source/libraries/ContractInterfaces.ts on lines 1030..1035
source/libraries/ContractInterfaces.ts on lines 1044..1049
source/libraries/ContractInterfaces.ts on lines 1093..1098
source/libraries/ContractInterfaces.ts on lines 1184..1189
source/libraries/ContractInterfaces.ts on lines 1198..1203
source/libraries/ContractInterfaces.ts on lines 1296..1301
source/libraries/ContractInterfaces.ts on lines 1324..1329
source/libraries/ContractInterfaces.ts on lines 1373..1378
source/libraries/ContractInterfaces.ts on lines 2157..2162
source/libraries/ContractInterfaces.ts on lines 2241..2246
source/libraries/ContractInterfaces.ts on lines 2332..2337
source/libraries/ContractInterfaces.ts on lines 2374..2379
source/libraries/ContractInterfaces.ts on lines 2458..2463
source/libraries/ContractInterfaces.ts on lines 2514..2519
source/libraries/ContractInterfaces.ts on lines 2556..2561
source/libraries/ContractInterfaces.ts on lines 2570..2575
source/libraries/ContractInterfaces.ts on lines 2605..2610
source/libraries/ContractInterfaces.ts on lines 2640..2645
source/libraries/ContractInterfaces.ts on lines 2668..2673
source/libraries/ContractInterfaces.ts on lines 2752..2757
source/libraries/ContractInterfaces.ts on lines 2773..2778
source/libraries/ContractInterfaces.ts on lines 2864..2869
source/libraries/ContractInterfaces.ts on lines 2941..2946
source/libraries/ContractInterfaces.ts on lines 2962..2967
source/libraries/ContractInterfaces.ts on lines 3928..3933
source/libraries/ContractInterfaces.ts on lines 4005..4010
source/libraries/ContractInterfaces.ts on lines 4019..4024
source/libraries/ContractInterfaces.ts on lines 4117..4122
source/libraries/ContractInterfaces.ts on lines 4145..4150
source/libraries/ContractInterfaces.ts on lines 4194..4199
source/libraries/ContractInterfaces.ts on lines 4999..5004
source/libraries/ContractInterfaces.ts on lines 5020..5025
source/libraries/ContractInterfaces.ts on lines 5097..5102
source/libraries/ContractInterfaces.ts on lines 5174..5179
source/libraries/ContractInterfaces.ts on lines 5202..5207
source/libraries/ContractInterfaces.ts on lines 5307..5312
source/libraries/ContractInterfaces.ts on lines 5342..5347
source/libraries/ContractInterfaces.ts on lines 5398..5403
source/libraries/ContractInterfaces.ts on lines 5552..5557
source/libraries/ContractInterfaces.ts on lines 5713..5718
source/libraries/ContractInterfaces.ts on lines 5853..5858
source/libraries/ContractInterfaces.ts on lines 5867..5872
source/libraries/ContractInterfaces.ts on lines 5937..5942
source/libraries/ContractInterfaces.ts on lines 6014..6019
source/libraries/ContractInterfaces.ts on lines 6035..6040
source/libraries/ContractInterfaces.ts on lines 6049..6054
source/libraries/ContractInterfaces.ts on lines 6063..6068

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 181.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 51 locations. Consider refactoring.
Open

        public publicBuyCompleteSetsWithCash_ = async(market: string, amount: BN, options?: { sender?: string }): Promise<boolean> => {
            options = options || {};
            const abi: AbiFunction = {"constant":false,"inputs":[{"name":"_market","type":"address"},{"name":"_amount","type":"uint256"}],"name":"publicBuyCompleteSetsWithCash","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"};
            const result = await this.localCall(abi, [market, amount], options.sender);
            return <boolean>result[0];
Severity: Major
Found in source/libraries/ContractInterfaces.ts and 50 other locations - About 7 hrs to fix
source/libraries/ContractInterfaces.ts on lines 498..503
source/libraries/ContractInterfaces.ts on lines 897..902
source/libraries/ContractInterfaces.ts on lines 981..986
source/libraries/ContractInterfaces.ts on lines 1030..1035
source/libraries/ContractInterfaces.ts on lines 1044..1049
source/libraries/ContractInterfaces.ts on lines 1093..1098
source/libraries/ContractInterfaces.ts on lines 1184..1189
source/libraries/ContractInterfaces.ts on lines 1198..1203
source/libraries/ContractInterfaces.ts on lines 1296..1301
source/libraries/ContractInterfaces.ts on lines 1324..1329
source/libraries/ContractInterfaces.ts on lines 1373..1378
source/libraries/ContractInterfaces.ts on lines 2157..2162
source/libraries/ContractInterfaces.ts on lines 2241..2246
source/libraries/ContractInterfaces.ts on lines 2332..2337
source/libraries/ContractInterfaces.ts on lines 2374..2379
source/libraries/ContractInterfaces.ts on lines 2458..2463
source/libraries/ContractInterfaces.ts on lines 2514..2519
source/libraries/ContractInterfaces.ts on lines 2556..2561
source/libraries/ContractInterfaces.ts on lines 2570..2575
source/libraries/ContractInterfaces.ts on lines 2605..2610
source/libraries/ContractInterfaces.ts on lines 2640..2645
source/libraries/ContractInterfaces.ts on lines 2668..2673
source/libraries/ContractInterfaces.ts on lines 2752..2757
source/libraries/ContractInterfaces.ts on lines 2773..2778
source/libraries/ContractInterfaces.ts on lines 2864..2869
source/libraries/ContractInterfaces.ts on lines 2941..2946
source/libraries/ContractInterfaces.ts on lines 2962..2967
source/libraries/ContractInterfaces.ts on lines 3928..3933
source/libraries/ContractInterfaces.ts on lines 4005..4010
source/libraries/ContractInterfaces.ts on lines 4019..4024
source/libraries/ContractInterfaces.ts on lines 4117..4122
source/libraries/ContractInterfaces.ts on lines 4145..4150
source/libraries/ContractInterfaces.ts on lines 4194..4199
source/libraries/ContractInterfaces.ts on lines 4999..5004
source/libraries/ContractInterfaces.ts on lines 5020..5025
source/libraries/ContractInterfaces.ts on lines 5097..5102
source/libraries/ContractInterfaces.ts on lines 5153..5158
source/libraries/ContractInterfaces.ts on lines 5174..5179
source/libraries/ContractInterfaces.ts on lines 5202..5207
source/libraries/ContractInterfaces.ts on lines 5342..5347
source/libraries/ContractInterfaces.ts on lines 5398..5403
source/libraries/ContractInterfaces.ts on lines 5552..5557
source/libraries/ContractInterfaces.ts on lines 5713..5718
source/libraries/ContractInterfaces.ts on lines 5853..5858
source/libraries/ContractInterfaces.ts on lines 5867..5872
source/libraries/ContractInterfaces.ts on lines 5937..5942
source/libraries/ContractInterfaces.ts on lines 6014..6019
source/libraries/ContractInterfaces.ts on lines 6035..6040
source/libraries/ContractInterfaces.ts on lines 6049..6054
source/libraries/ContractInterfaces.ts on lines 6063..6068

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 181.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 51 locations. Consider refactoring.
Open

        public incrementTotalEscrowed_ = async(market: string, amount: BN, options?: { sender?: string }): Promise<boolean> => {
            options = options || {};
            const abi: AbiFunction = {"constant":false,"inputs":[{"name":"_market","type":"address"},{"name":"_amount","type":"uint256"}],"name":"incrementTotalEscrowed","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"};
            const result = await this.localCall(abi, [market, amount], options.sender);
            return <boolean>result[0];
Severity: Major
Found in source/libraries/ContractInterfaces.ts and 50 other locations - About 7 hrs to fix
source/libraries/ContractInterfaces.ts on lines 498..503
source/libraries/ContractInterfaces.ts on lines 897..902
source/libraries/ContractInterfaces.ts on lines 981..986
source/libraries/ContractInterfaces.ts on lines 1030..1035
source/libraries/ContractInterfaces.ts on lines 1044..1049
source/libraries/ContractInterfaces.ts on lines 1093..1098
source/libraries/ContractInterfaces.ts on lines 1184..1189
source/libraries/ContractInterfaces.ts on lines 1198..1203
source/libraries/ContractInterfaces.ts on lines 1296..1301
source/libraries/ContractInterfaces.ts on lines 1324..1329
source/libraries/ContractInterfaces.ts on lines 1373..1378
source/libraries/ContractInterfaces.ts on lines 2157..2162
source/libraries/ContractInterfaces.ts on lines 2241..2246
source/libraries/ContractInterfaces.ts on lines 2332..2337
source/libraries/ContractInterfaces.ts on lines 2374..2379
source/libraries/ContractInterfaces.ts on lines 2458..2463
source/libraries/ContractInterfaces.ts on lines 2514..2519
source/libraries/ContractInterfaces.ts on lines 2556..2561
source/libraries/ContractInterfaces.ts on lines 2570..2575
source/libraries/ContractInterfaces.ts on lines 2605..2610
source/libraries/ContractInterfaces.ts on lines 2640..2645
source/libraries/ContractInterfaces.ts on lines 2668..2673
source/libraries/ContractInterfaces.ts on lines 2752..2757
source/libraries/ContractInterfaces.ts on lines 2773..2778
source/libraries/ContractInterfaces.ts on lines 2864..2869
source/libraries/ContractInterfaces.ts on lines 2941..2946
source/libraries/ContractInterfaces.ts on lines 2962..2967
source/libraries/ContractInterfaces.ts on lines 3928..3933
source/libraries/ContractInterfaces.ts on lines 4005..4010
source/libraries/ContractInterfaces.ts on lines 4019..4024
source/libraries/ContractInterfaces.ts on lines 4117..4122
source/libraries/ContractInterfaces.ts on lines 4145..4150
source/libraries/ContractInterfaces.ts on lines 4194..4199
source/libraries/ContractInterfaces.ts on lines 4999..5004
source/libraries/ContractInterfaces.ts on lines 5020..5025
source/libraries/ContractInterfaces.ts on lines 5097..5102
source/libraries/ContractInterfaces.ts on lines 5153..5158
source/libraries/ContractInterfaces.ts on lines 5174..5179
source/libraries/ContractInterfaces.ts on lines 5202..5207
source/libraries/ContractInterfaces.ts on lines 5307..5312
source/libraries/ContractInterfaces.ts on lines 5342..5347
source/libraries/ContractInterfaces.ts on lines 5398..5403
source/libraries/ContractInterfaces.ts on lines 5713..5718
source/libraries/ContractInterfaces.ts on lines 5853..5858
source/libraries/ContractInterfaces.ts on lines 5867..5872
source/libraries/ContractInterfaces.ts on lines 5937..5942
source/libraries/ContractInterfaces.ts on lines 6014..6019
source/libraries/ContractInterfaces.ts on lines 6035..6040
source/libraries/ContractInterfaces.ts on lines 6049..6054
source/libraries/ContractInterfaces.ts on lines 6063..6068

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 181.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 51 locations. Consider refactoring.
Open

        public initialize_ = async(market: string, outcome: BN, options?: { sender?: string }): Promise<boolean> => {
            options = options || {};
            const abi: AbiFunction = {"constant":false,"inputs":[{"name":"_market","type":"address"},{"name":"_outcome","type":"uint256"}],"name":"initialize","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"};
            const result = await this.localCall(abi, [market, outcome], options.sender);
            return <boolean>result[0];
Severity: Major
Found in source/libraries/ContractInterfaces.ts and 50 other locations - About 7 hrs to fix
source/libraries/ContractInterfaces.ts on lines 498..503
source/libraries/ContractInterfaces.ts on lines 897..902
source/libraries/ContractInterfaces.ts on lines 981..986
source/libraries/ContractInterfaces.ts on lines 1030..1035
source/libraries/ContractInterfaces.ts on lines 1044..1049
source/libraries/ContractInterfaces.ts on lines 1093..1098
source/libraries/ContractInterfaces.ts on lines 1184..1189
source/libraries/ContractInterfaces.ts on lines 1198..1203
source/libraries/ContractInterfaces.ts on lines 1296..1301
source/libraries/ContractInterfaces.ts on lines 1324..1329
source/libraries/ContractInterfaces.ts on lines 1373..1378
source/libraries/ContractInterfaces.ts on lines 2157..2162
source/libraries/ContractInterfaces.ts on lines 2241..2246
source/libraries/ContractInterfaces.ts on lines 2332..2337
source/libraries/ContractInterfaces.ts on lines 2374..2379
source/libraries/ContractInterfaces.ts on lines 2458..2463
source/libraries/ContractInterfaces.ts on lines 2514..2519
source/libraries/ContractInterfaces.ts on lines 2556..2561
source/libraries/ContractInterfaces.ts on lines 2570..2575
source/libraries/ContractInterfaces.ts on lines 2605..2610
source/libraries/ContractInterfaces.ts on lines 2640..2645
source/libraries/ContractInterfaces.ts on lines 2668..2673
source/libraries/ContractInterfaces.ts on lines 2752..2757
source/libraries/ContractInterfaces.ts on lines 2773..2778
source/libraries/ContractInterfaces.ts on lines 2864..2869
source/libraries/ContractInterfaces.ts on lines 2941..2946
source/libraries/ContractInterfaces.ts on lines 2962..2967
source/libraries/ContractInterfaces.ts on lines 3928..3933
source/libraries/ContractInterfaces.ts on lines 4005..4010
source/libraries/ContractInterfaces.ts on lines 4019..4024
source/libraries/ContractInterfaces.ts on lines 4117..4122
source/libraries/ContractInterfaces.ts on lines 4145..4150
source/libraries/ContractInterfaces.ts on lines 4194..4199
source/libraries/ContractInterfaces.ts on lines 4999..5004
source/libraries/ContractInterfaces.ts on lines 5020..5025
source/libraries/ContractInterfaces.ts on lines 5097..5102
source/libraries/ContractInterfaces.ts on lines 5153..5158
source/libraries/ContractInterfaces.ts on lines 5174..5179
source/libraries/ContractInterfaces.ts on lines 5202..5207
source/libraries/ContractInterfaces.ts on lines 5307..5312
source/libraries/ContractInterfaces.ts on lines 5342..5347
source/libraries/ContractInterfaces.ts on lines 5398..5403
source/libraries/ContractInterfaces.ts on lines 5552..5557
source/libraries/ContractInterfaces.ts on lines 5713..5718
source/libraries/ContractInterfaces.ts on lines 5853..5858
source/libraries/ContractInterfaces.ts on lines 5867..5872
source/libraries/ContractInterfaces.ts on lines 5937..5942
source/libraries/ContractInterfaces.ts on lines 6014..6019
source/libraries/ContractInterfaces.ts on lines 6049..6054
source/libraries/ContractInterfaces.ts on lines 6063..6068

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 181.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 51 locations. Consider refactoring.
Open

        public destroyShares_ = async(owner: string, fxpValue: BN, options?: { sender?: string }): Promise<boolean> => {
            options = options || {};
            const abi: AbiFunction = {"constant":false,"inputs":[{"name":"_owner","type":"address"},{"name":"_fxpValue","type":"uint256"}],"name":"destroyShares","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"};
            const result = await this.localCall(abi, [owner, fxpValue], options.sender);
            return <boolean>result[0];
Severity: Major
Found in source/libraries/ContractInterfaces.ts and 50 other locations - About 7 hrs to fix
source/libraries/ContractInterfaces.ts on lines 498..503
source/libraries/ContractInterfaces.ts on lines 897..902
source/libraries/ContractInterfaces.ts on lines 981..986
source/libraries/ContractInterfaces.ts on lines 1030..1035
source/libraries/ContractInterfaces.ts on lines 1044..1049
source/libraries/ContractInterfaces.ts on lines 1093..1098
source/libraries/ContractInterfaces.ts on lines 1184..1189
source/libraries/ContractInterfaces.ts on lines 1198..1203
source/libraries/ContractInterfaces.ts on lines 1296..1301
source/libraries/ContractInterfaces.ts on lines 1324..1329
source/libraries/ContractInterfaces.ts on lines 1373..1378
source/libraries/ContractInterfaces.ts on lines 2157..2162
source/libraries/ContractInterfaces.ts on lines 2241..2246
source/libraries/ContractInterfaces.ts on lines 2332..2337
source/libraries/ContractInterfaces.ts on lines 2374..2379
source/libraries/ContractInterfaces.ts on lines 2458..2463
source/libraries/ContractInterfaces.ts on lines 2514..2519
source/libraries/ContractInterfaces.ts on lines 2556..2561
source/libraries/ContractInterfaces.ts on lines 2570..2575
source/libraries/ContractInterfaces.ts on lines 2605..2610
source/libraries/ContractInterfaces.ts on lines 2640..2645
source/libraries/ContractInterfaces.ts on lines 2668..2673
source/libraries/ContractInterfaces.ts on lines 2752..2757
source/libraries/ContractInterfaces.ts on lines 2773..2778
source/libraries/ContractInterfaces.ts on lines 2864..2869
source/libraries/ContractInterfaces.ts on lines 2941..2946
source/libraries/ContractInterfaces.ts on lines 2962..2967
source/libraries/ContractInterfaces.ts on lines 3928..3933
source/libraries/ContractInterfaces.ts on lines 4005..4010
source/libraries/ContractInterfaces.ts on lines 4019..4024
source/libraries/ContractInterfaces.ts on lines 4117..4122
source/libraries/ContractInterfaces.ts on lines 4145..4150
source/libraries/ContractInterfaces.ts on lines 4194..4199
source/libraries/ContractInterfaces.ts on lines 4999..5004
source/libraries/ContractInterfaces.ts on lines 5020..5025
source/libraries/ContractInterfaces.ts on lines 5097..5102
source/libraries/ContractInterfaces.ts on lines 5153..5158
source/libraries/ContractInterfaces.ts on lines 5174..5179
source/libraries/ContractInterfaces.ts on lines 5202..5207
source/libraries/ContractInterfaces.ts on lines 5307..5312
source/libraries/ContractInterfaces.ts on lines 5342..5347
source/libraries/ContractInterfaces.ts on lines 5398..5403
source/libraries/ContractInterfaces.ts on lines 5552..5557
source/libraries/ContractInterfaces.ts on lines 5713..5718
source/libraries/ContractInterfaces.ts on lines 5853..5858
source/libraries/ContractInterfaces.ts on lines 5867..5872
source/libraries/ContractInterfaces.ts on lines 5937..5942
source/libraries/ContractInterfaces.ts on lines 6014..6019
source/libraries/ContractInterfaces.ts on lines 6035..6040
source/libraries/ContractInterfaces.ts on lines 6063..6068

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 181.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 51 locations. Consider refactoring.
Open

        public increaseApproval_ = async(spender: string, addedValue: BN, options?: { sender?: string }): Promise<boolean> => {
            options = options || {};
            const abi: AbiFunction = {"constant":false,"inputs":[{"name":"_spender","type":"address"},{"name":"_addedValue","type":"uint256"}],"name":"increaseApproval","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"};
            const result = await this.localCall(abi, [spender, addedValue], options.sender);
            return <boolean>result[0];
Severity: Major
Found in source/libraries/ContractInterfaces.ts and 50 other locations - About 7 hrs to fix
source/libraries/ContractInterfaces.ts on lines 498..503
source/libraries/ContractInterfaces.ts on lines 897..902
source/libraries/ContractInterfaces.ts on lines 981..986
source/libraries/ContractInterfaces.ts on lines 1030..1035
source/libraries/ContractInterfaces.ts on lines 1044..1049
source/libraries/ContractInterfaces.ts on lines 1093..1098
source/libraries/ContractInterfaces.ts on lines 1184..1189
source/libraries/ContractInterfaces.ts on lines 1198..1203
source/libraries/ContractInterfaces.ts on lines 1296..1301
source/libraries/ContractInterfaces.ts on lines 1324..1329
source/libraries/ContractInterfaces.ts on lines 1373..1378
source/libraries/ContractInterfaces.ts on lines 2157..2162
source/libraries/ContractInterfaces.ts on lines 2241..2246
source/libraries/ContractInterfaces.ts on lines 2332..2337
source/libraries/ContractInterfaces.ts on lines 2374..2379
source/libraries/ContractInterfaces.ts on lines 2458..2463
source/libraries/ContractInterfaces.ts on lines 2514..2519
source/libraries/ContractInterfaces.ts on lines 2556..2561
source/libraries/ContractInterfaces.ts on lines 2570..2575
source/libraries/ContractInterfaces.ts on lines 2605..2610
source/libraries/ContractInterfaces.ts on lines 2640..2645
source/libraries/ContractInterfaces.ts on lines 2668..2673
source/libraries/ContractInterfaces.ts on lines 2752..2757
source/libraries/ContractInterfaces.ts on lines 2773..2778
source/libraries/ContractInterfaces.ts on lines 2864..2869
source/libraries/ContractInterfaces.ts on lines 2941..2946
source/libraries/ContractInterfaces.ts on lines 2962..2967
source/libraries/ContractInterfaces.ts on lines 3928..3933
source/libraries/ContractInterfaces.ts on lines 4005..4010
source/libraries/ContractInterfaces.ts on lines 4019..4024
source/libraries/ContractInterfaces.ts on lines 4117..4122
source/libraries/ContractInterfaces.ts on lines 4145..4150
source/libraries/ContractInterfaces.ts on lines 4194..4199
source/libraries/ContractInterfaces.ts on lines 4999..5004
source/libraries/ContractInterfaces.ts on lines 5020..5025
source/libraries/ContractInterfaces.ts on lines 5097..5102
source/libraries/ContractInterfaces.ts on lines 5153..5158
source/libraries/ContractInterfaces.ts on lines 5174..5179
source/libraries/ContractInterfaces.ts on lines 5202..5207
source/libraries/ContractInterfaces.ts on lines 5307..5312
source/libraries/ContractInterfaces.ts on lines 5342..5347
source/libraries/ContractInterfaces.ts on lines 5398..5403
source/libraries/ContractInterfaces.ts on lines 5552..5557
source/libraries/ContractInterfaces.ts on lines 5713..5718
source/libraries/ContractInterfaces.ts on lines 5853..5858
source/libraries/ContractInterfaces.ts on lines 5867..5872
source/libraries/ContractInterfaces.ts on lines 5937..5942
source/libraries/ContractInterfaces.ts on lines 6014..6019
source/libraries/ContractInterfaces.ts on lines 6035..6040
source/libraries/ContractInterfaces.ts on lines 6049..6054

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 181.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 51 locations. Consider refactoring.
Open

        public migrateIn_ = async(reporter: string, attotokens: BN, options?: { sender?: string }): Promise<boolean> => {
            options = options || {};
            const abi: AbiFunction = {"constant":false,"inputs":[{"name":"_reporter","type":"address"},{"name":"_attotokens","type":"uint256"}],"name":"migrateIn","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"};
            const result = await this.localCall(abi, [reporter, attotokens], options.sender);
            return <boolean>result[0];
Severity: Major
Found in source/libraries/ContractInterfaces.ts and 50 other locations - About 7 hrs to fix
source/libraries/ContractInterfaces.ts on lines 498..503
source/libraries/ContractInterfaces.ts on lines 897..902
source/libraries/ContractInterfaces.ts on lines 981..986
source/libraries/ContractInterfaces.ts on lines 1030..1035
source/libraries/ContractInterfaces.ts on lines 1044..1049
source/libraries/ContractInterfaces.ts on lines 1093..1098
source/libraries/ContractInterfaces.ts on lines 1184..1189
source/libraries/ContractInterfaces.ts on lines 1198..1203
source/libraries/ContractInterfaces.ts on lines 1296..1301
source/libraries/ContractInterfaces.ts on lines 1324..1329
source/libraries/ContractInterfaces.ts on lines 1373..1378
source/libraries/ContractInterfaces.ts on lines 2157..2162
source/libraries/ContractInterfaces.ts on lines 2241..2246
source/libraries/ContractInterfaces.ts on lines 2332..2337
source/libraries/ContractInterfaces.ts on lines 2374..2379
source/libraries/ContractInterfaces.ts on lines 2458..2463
source/libraries/ContractInterfaces.ts on lines 2514..2519
source/libraries/ContractInterfaces.ts on lines 2556..2561
source/libraries/ContractInterfaces.ts on lines 2570..2575
source/libraries/ContractInterfaces.ts on lines 2605..2610
source/libraries/ContractInterfaces.ts on lines 2640..2645
source/libraries/ContractInterfaces.ts on lines 2668..2673
source/libraries/ContractInterfaces.ts on lines 2752..2757
source/libraries/ContractInterfaces.ts on lines 2773..2778
source/libraries/ContractInterfaces.ts on lines 2864..2869
source/libraries/ContractInterfaces.ts on lines 2941..2946
source/libraries/ContractInterfaces.ts on lines 2962..2967
source/libraries/ContractInterfaces.ts on lines 3928..3933
source/libraries/ContractInterfaces.ts on lines 4005..4010
source/libraries/ContractInterfaces.ts on lines 4019..4024
source/libraries/ContractInterfaces.ts on lines 4145..4150
source/libraries/ContractInterfaces.ts on lines 4194..4199
source/libraries/ContractInterfaces.ts on lines 4999..5004
source/libraries/ContractInterfaces.ts on lines 5020..5025
source/libraries/ContractInterfaces.ts on lines 5097..5102
source/libraries/ContractInterfaces.ts on lines 5153..5158
source/libraries/ContractInterfaces.ts on lines 5174..5179
source/libraries/ContractInterfaces.ts on lines 5202..5207
source/libraries/ContractInterfaces.ts on lines 5307..5312
source/libraries/ContractInterfaces.ts on lines 5342..5347
source/libraries/ContractInterfaces.ts on lines 5398..5403
source/libraries/ContractInterfaces.ts on lines 5552..5557
source/libraries/ContractInterfaces.ts on lines 5713..5718
source/libraries/ContractInterfaces.ts on lines 5853..5858
source/libraries/ContractInterfaces.ts on lines 5867..5872
source/libraries/ContractInterfaces.ts on lines 5937..5942
source/libraries/ContractInterfaces.ts on lines 6014..6019
source/libraries/ContractInterfaces.ts on lines 6035..6040
source/libraries/ContractInterfaces.ts on lines 6049..6054
source/libraries/ContractInterfaces.ts on lines 6063..6068

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 181.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Severity
Category
Status
Source
Language