1/* eslint-disable no-undef */ 2 3(function ($, Drupal, drupalSettings) { 4 5 'use strict'; 6 7 function getUrlParam(param) { 8 var params = new URLSearchParams(location.search); 9 var value = params.get(param); 10 11 return value; 12 } 13 14 function getSlateSpidUrl() { 15 var spid = getUrlParam('salink'); 16 var sasource = getUrlParam('sasource'); 17 var tc_ptid = getNested(AcquiaLift, 'liftWebIdentity', 'tc_ptid'); 18 19 if (spid) { 20 _tcaq.push(['updatePerson', {person_udf5: spid}]); 21 _tcaq.push(['captureIdentity', spid, 'account']); 22 if (tc_ptid) { 23 var Http = new XMLHttpRequest(); 24 var url = '/pace_slate_lift/getGuid?salink=' + spid + '&tc_ptid=' + tc_ptid + '&sasource=' + sasource; 25 Http.open('GET', url); 26 Http.send(); 27 } 28 } 29 } 30 31 function getNested(obj, ...args) { 32 return args.reduce((obj, level) => obj && obj[level], obj); 33 } 34 35 window.addEventListener('acquiaLiftStageCollection', function() { 36 getSlateSpidUrl(); 37 }); 38 39})(jQuery, Drupal, drupalSettings); 40 41
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.