List.prototype._findFile = function (path, pattern) { if (!path || !pattern) return if (!this.buckets.has(pattern.pattern)) return return _.find(from(this.buckets.get(pattern.pattern)), function (file) { return file.originalPath === path }) }
/** * Updates the running queue for the associated auction. * Does a check to ensure the auction is still running; if it's not - the previously running queue is killed. * @param {*} auctionInstance running context of the auction * @param {Object} bidResponse bid object being added to queue * @param {Function} afterBidAdded callback function used when Prebid Cache responds */ function updateBidQueue(auctionInstance, bidResponse, afterBidAdded) { let bidListIter = bidCacheRegistry.getBids(bidResponse); if (bidListIter) { let bidListArr = from(bidListIter); let callDispatcher = bidCacheRegistry.getQueueDispatcher(bidResponse); let killQueue = !!(auctionInstance.getAuctionStatus() !== AUCTION_IN_PROGRESS); callDispatcher(auctionInstance, bidListArr, afterBidAdded, killQueue); } else { utils.logWarn('Attempted to cache a bid from an unknown auction. Bid:', bidResponse); } }
.map(function (p) { return from(self.buckets.get(p.pattern)).sort(byPath) })
function findFile (path, files) { return from(files).find((file) => file.path === path) }
function pathsFrom (files) { return _.pluck(from(files), 'path') }
var findByPath = function (files, path) { return _.find(from(files), function (file) { return file.path === path }) }
var expandPattern = function (p) { return from(self.buckets.get(p.pattern) || []).sort(byPath) }