Add ForwarderHelperImplConfig

This commit is contained in:
Brandon Millman
2018-08-17 13:00:54 -07:00
parent 3c973ba9f6
commit e8a1950a74
6 changed files with 104 additions and 38 deletions

View File

@@ -32,7 +32,7 @@ export const sortingUtils = {
* the makerAsset and WETH as the takerAsset.
* @return The input orders sorted by rate in ascending order
*/
sortFeeOrdersByFeeAdjustedRate(feeOrders: Order[]): Order[] {
sortFeeOrdersByFeeAdjustedRate<T extends Order>(feeOrders: T[]): T[] {
assert.doesConformToSchema('feeOrders', feeOrders, schemas.ordersSchema);
const rateCalculator = rateUtils.getFeeAdjustedRateOfFeeOrder.bind(rateUtils);
const sortedOrders = sortOrders(feeOrders, rateCalculator);