Skip to content

Commit

Permalink
Ensuring that ref parameter is always set to correct value in sonobi …
Browse files Browse the repository at this point in the history
…requests (#712)
  • Loading branch information
edahood-sonobi authored and Nate Cozi committed Oct 18, 2016
1 parent a10c326 commit d6adf1e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/adapters/sonobi.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ var SonobiAdapter = function SonobiAdapter(){
var trinity = 'https://apex.go.sonobi.com/trinity.js?key_maker=';
var adSlots = request.bids || [];
var bidderRequestId = request.bidderRequestId;
var ref = (window.frameElement) ? encodeURI(top.location.host || document.referrer) : null;
adloader.loadScript(trinity + JSON.stringify(_keymaker(adSlots)) + '&cv=' + _operator(bidderRequestId) + (ref) ? '&ref=' + ref : '');
var ref = (window.frameElement) ? '&ref=' + encodeURI(top.location.host || document.referrer) : '';
adloader.loadScript(trinity + JSON.stringify(_keymaker(adSlots)) + '&cv=' + _operator(bidderRequestId) + ref );
}

function _keymaker(adSlots){
Expand Down

0 comments on commit d6adf1e

Please sign in to comment.