aboutsummaryrefslogtreecommitdiffstats
path: root/packages/order-utils/src/parsing_utils.ts
diff options
context:
space:
mode:
Diffstat (limited to 'packages/order-utils/src/parsing_utils.ts')
-rw-r--r--packages/order-utils/src/parsing_utils.ts27
1 files changed, 0 insertions, 27 deletions
diff --git a/packages/order-utils/src/parsing_utils.ts b/packages/order-utils/src/parsing_utils.ts
deleted file mode 100644
index 98c6899fe..000000000
--- a/packages/order-utils/src/parsing_utils.ts
+++ /dev/null
@@ -1,27 +0,0 @@
-import { BigNumber } from '@0x/utils';
-import * as _ from 'lodash';
-
-export const orderParsingUtils = {
- convertStringsFieldsToBigNumbers(obj: any, fields: string[]): any {
- const result = _.assign({}, obj);
- _.each(fields, field => {
- _.update(result, field, (value: string) => {
- if (_.isUndefined(value)) {
- throw new Error(`Could not find field '${field}' while converting string fields to BigNumber.`);
- }
- return new BigNumber(value);
- });
- });
- return result;
- },
- convertOrderStringFieldsToBigNumber(order: any): any {
- return orderParsingUtils.convertStringsFieldsToBigNumbers(order, [
- 'makerAssetAmount',
- 'takerAssetAmount',
- 'makerFee',
- 'takerFee',
- 'expirationTimeSeconds',
- 'salt',
- ]);
- },
-};