Gollum to Programmer Humor@programming.dev • 1 year agoPOV: Working at Googlefeddit.deimagemessage-square15fedilinkarrow-up1626arrow-down122
arrow-up1604arrow-down1imagePOV: Working at Googlefeddit.deGollum to Programmer Humor@programming.dev • 1 year agomessage-square15fedilink
minus-square7heolinkfedilink26•1 year agoThat isn’t real. It wouldn’t pass peer review. Here is the actual code: function GetCookieValue(x) { return JSON.stringify(x); } user.cookies.agreed = Boolean(GetCookieValue(true)); if(!DarkPatternPopup()) { // Make sure we respect the user choice user.cookies.agreed = Boolean(GetCookieValue(false)); } if(user.cookies.agreed) CollectData(user);
That isn’t real. It wouldn’t pass peer review. Here is the actual code:
function GetCookieValue(x) { return JSON.stringify(x); } user.cookies.agreed = Boolean(GetCookieValue(true)); if(!DarkPatternPopup()) { // Make sure we respect the user choice user.cookies.agreed = Boolean(GetCookieValue(false)); } if(user.cookies.agreed) CollectData(user);