Skip to content

Commit

Permalink
fix find issue in rubiconBidAdapter_spec.js file (#2613)
Browse files Browse the repository at this point in the history
  • Loading branch information
jsnellbaker authored and mkendall07 committed May 24, 2018
1 parent 7570a6b commit f022c16
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions test/spec/modules/rubiconBidAdapter_spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import {newBidder} from 'src/adapters/bidderFactory';
import {userSync} from 'src/userSync';
import {config} from 'src/config';
import * as utils from 'src/utils';
import find from 'core-js/library/fn/array/find';

var CONSTANTS = require('src/constants.json');

Expand All @@ -31,7 +32,7 @@ describe('the rubicon adapter', () => {
* @return {sizeMapConverted}
*/
function getSizeIdForBid(sizesMapConverted, bid) {
return sizesMapConverted.find(item => (item.width === bid.width && item.height === bid.height));
return find(sizesMapConverted, item => (item.width === bid.width && item.height === bid.height));
}

/**
Expand All @@ -40,7 +41,7 @@ describe('the rubicon adapter', () => {
* @return {Object}
*/
function getResponseAdBySize(ads, size) {
return ads.find(item => item.size_id === size.sizeId);
return find(ads, item => item.size_id === size.sizeId);
}

/**
Expand All @@ -49,7 +50,7 @@ describe('the rubicon adapter', () => {
* @return {BidRequest}
*/
function getBidRequestBySize(bidRequests, size) {
return bidRequests.find(item => item.sizes[0][0] === size.width && item.sizes[0][1] === size.height);
return find(bidRequests, item => item.sizes[0][0] === size.width && item.sizes[0][1] === size.height);
}

/**
Expand Down

0 comments on commit f022c16

Please sign in to comment.