module.exports = "(function(e,n,t){var o=t(5894),i=t(280).v,r=t(9404),s=t(8737),a=t(7152),d=t(7358),c=t(4527),u=t(1571),f=c.get(\"stores/cookie_options\"),p=n.SetError=i(\"CookieSetError\"),g=n.MismatchError=i(\"CookieMismatchError\"),h=[\"co\",\"com\",\"net\",\"org\",\"edu\",\"gov\",\"mil\",\"int\",\"ac\",\"com\",\"net\",\"org\"];n.getAll=function(e){var t,i,r,a,d;o.isUndefined(e)&&(e=!0),t=s.getCookieString().split(/\\s*;\\s*/);var c={};for(r=0;r<t.length;r++)if((a=(i=t[r]).indexOf(\"=\"))>0&&void 0===c[d=n.safeDecodeURIComponent(i.substring(0,a))]){var u=i.substring(a+1);e&&(u=n.safeDecodeURIComponent(u)),c[d]=u}return c},n.safeDecodeURIComponent=function(e){try{return decodeURIComponent(e)}catch(n){return e}},n.get=function(e,t){return n.getAll(t)[e]},n.set=function(e,i,c,S){c=o.extend({encodeValue:!0},c),!1!==S&&(S=!0),__INVARIANT__&&t(2048).isType(\"CookieOptions\",c);var _=[];if(o.isUndefined(c.domain)){var C=f.getCurrentDomain();C||(C=function(e,t){!1!==t&&(t=!0);for(var i,r,s=e.hostname.split(\".\"),a=[],c=null,f=s.length-1;f>=0;f--)if(a.unshift(s[f]),i=a.join(\".\"),!(s.length>1&&(1===a.length||2===a.length&&h.includes(a[0]))||o.includes(l,i))){r={domain:t?\".\"+i:i};try{n.set(m,Math.random().toString(),r),n.remove(m,r),c=r.domain;break}catch(e){}}return u.dispatch(d.SET_COOKIE_DOMAIN,c),c}(a.getLocation(),!0)),c.domain=C}if(c.domain&&_.push(\"domain=\"+c.domain),o.isUndefined(c.path)&&(c.path=\"/\"),c.path&&_.push(\"path=\"+c.path),o.isUndefined(c.expires)){var E=o.isUndefined(c.maxAge)?f.getDefaultAgeInSeconds():c.maxAge;c.expires=new Date(r.now()+1e3*E)}if(o.isUndefined(c.expires)||_.push(\"expires=\"+c.expires.toUTCString()),__SET_SECURE_CROSSSITE_COOKIES__&&_.push(\"SameSite=None\"),(__SET_SECURE_CROSSSITE_COOKIES__||c.secure)&&_.push(\"secure\"),s.setCookie(e+\"=\"+(c.encodeValue?encodeURIComponent(i):i)+\";\"+_.join(\";\")),S){var v=c.encodeValue,I=n.get(e,v);if(I!==i){if(!I)throw new p('Failed to set cookie \"'+e+'\"');throw new g('Expected \"'+i+'\" for \"'+e+'\", got \"'+I+'\"')}}},n.remove=function(e,t){for(var i=a.getLocation().hostname.split(\".\"),r=1===i.length?0:1;i.length>r&&(2!==i.length||!h.includes(i[0]));)n.set(e,null,o.extend({},t,{domain:\".\"+i.join(\".\"),expires:new Date(0)}),!1),i.shift()};var l=[\"optimizely.test\"],m=\"optimizelyDomainTestCookie\";0})";