window._ty_rum&&window._ty_rum.server||function(r){function t(){}function e(){var r=y(rr);return r||(r=k(),z(rr,r)),r}function n(r){if("string"!=typeof r)return null;var t=i.cookie;if(!t)return null;var e=null,n=t.split(";");return f.each(n,function(t){var n=t.split("=");if(f.trim(n[0])===f.trim(r))return e=n[1],!0}),e}function a(r,t,e){var n=r+"="+t;if(e){var a=new date;a.settime(a.gettime()+1e3*e),n+=";expires="+a.togmtstring()}i.cookie=n}function o(r){switch(typeof r){case"object":if(!r)return"null";if(r instanceof array){for(var t="[",e=0;e0?",":"")+o(r[e]);return t+"]"}if(r instanceof date)return r.gettime().tostring();var t="{",e=0;for(var n in r)if("function"!=typeof r[n]){var a=o(r[n]);t+=(e>0?",":"")+o(n)+":"+a,e++}return t+"}";case"string":return'"'+r.replace(/([\"\\])/g,"\\$1").replace(/\n/g,"\\n")+'"';case"number":return r.tostring();case"boolean":return r?"true":"false";case"function":return o(r.tostring());case"undefined":default:return'"undefined"'}}function i(r){for(var t in r)return!1;return!0}function s(r){return a?a(r):r}function c(){return date.now?date.now():(new date).valueof()}function u(r,t,e){function n(){var r=f.args.apply(this,arguments);return t(o,r,e)}var a,o=r[r.length-1];if("function"==typeof o){switch(o.length){case 0:a=function(){return n.apply(this,arguments)};break;case 1:a=function(r){return n.apply(this,arguments)};break;case 2:a=function(r,t){return n.apply(this,arguments)};break;case 3:a=function(r,t,e){return n.apply(this,arguments)};break;case 4:a=function(r,t,e,a){return n.apply(this,arguments)};break;case 5:a=function(r,t,e,a,o){return n.apply(this,arguments)};break;default:for(var i=[],s=0,c=o.length;s"),n=i.createelement(i)}return n}function k(r){function t(){ir.send()}return!!j.load_time||(ir.initend(),j.load_time=c(),void(9===r?t():settimeout(t,0)))}function t(){cr||k(9),sr||f.bind(y,ir)(),cr=1}function e(){ir.touch||(ir.touch=c())}function x(r){if(r[6]){var t=r[4],e=r[5];if(e&&"string"==typeof e&&t){e=e.split(/\n/);var n=b.exec(e[0]);n||(n=b.exec(e[1])),n&&n[1]!=t&&(r[4]=n[1]||t,r[2]=n[2]||r[2],r[3]=n[3]||r[3])}}}function o(r,t,e,n){return string(r)+string(t)+string(e)+string(n)}function r(t){var e=arguments,n="unknown",a=[c()];if(0!=e.length){if("string"==typeof t){var o=e.length<4?e.length:4;a[1]=e[0],o>2&&(a[2]=e[2],a[3]=0,a[4]=e[1]),o>3&&e[3]&&(a[3]=e[3])}else if(t instanceof event||r.errorevent&&t instanceof errorevent){if(a[1]=t.message||(t.error&&t.error.constructor.name)+(t.error&&t.error.message)||"",a[2]=t.lineno?t.lineno:0,a[3]=t.colno?t.colno:0,a[4]=t.filename||t.error&&t.error.filename||t.target&&t.target.baseuri||"",!a[4]&&w)return;a[4]==i.url&&(a[4]="#"),t.error?(a[5]=t.error.stack,a[6]=t.error.modulename):(a[5]=null,a[6]=null);var i=o(a[1],a[2],a[3],a[6]);if(a[7]=ur[i]?0:1,ur[i]=!0,a[1]===n&&a[4]===n)return;x(a)}ir.errors.push(a)}}function q(r){return function(){var t=arguments;if(!this._ty_wrap){var e=f.args.apply(this,t);this._ty_rum={method:e[0],url:e[1],start:c()}}try{return r.apply(this,t)}catch(n){return function.prototype.apply.call(r,this,t)}}}function l(t){return"string"==typeof t?t.length:r.arraybuffer&&t instanceof arraybuffer?t.bytelength:r.blob&&t instanceof blob?t.size:t&&t.length?t.length:0}function c(t){return function(){function e(r){var t,e,n=u._ty_rum;if(n){if(4!==n.readystate&&(n.end=c()),n.s=u.status,""==u.responsetype||"text"==u.responsetype)n.res=l(u.responsetext);else if(u.response)n.res=l(u.response);else try{n.res=l(u.responsetext)}catch(o){n.res=0}if(n.readystate=u.readystate,n.cb_time=l,t=[n.method+" "+n.url,n.s>0?n.end-n.start:0,l,n.s,n.s>0?0:r,n.res,n.req],n.r&&(e=a(u),e&&(e=e.xdata)&&(t.push(e.id),t.push(e.action),t.push(e.time&&e.time.duration),t.push(e.time&&e.time.qu))),j.aa.push(t),j.server.custom_urls&&j.server.custom_urls.length&&!ir.ct){if(!j.pattern){j.pattern=[];for(var i=0;i2){var i=a[2];for(var u in i)o+="&"+u+"="+i[u]}return h.host&&(o+="&cshst="+s(h.host)),h.url&&(o+="&csurl="+s(h.url)),o},get:function(r,t){function e(){t&&t.apply(this,arguments),n.parentnode&&n.parentnode.removechild(n)}if(navigator&&navigator.sendbeacon&&q.test(r))return navigator.sendbeacon(r,null);var n=i.createelement("img");return n.setattribute("src",r),n.setattribute("style","display:none"),this.sh(n,"readystatechange",function(){"loaded"!=n.readystate&&4!=n.readystate||e("loaded")},!1),this.sh(n,"load",function(){return e("load"),!0},!1),this.sh(n,"error",function(){return e("error"),!0},!1),i.body.appendchild(n)},fpt:function(r,t,e){var n=s("div",{style:"display:none"},!1),a=s("iframe",{name:"_ty_rum_frm",width:0,height:0,style:"display:none"},!1),o=s("form",{style:"display:none",action:r,enctype:"application/x-www-form-urlencoded",method:"post",target:"_ty_rum_frm"},!1),i=s("input",{name:"data",type:"hidden"},!0);return i.value=t,o.appendchild(i),n.appendchild(a),n.appendchild(o),i.body.appendchild(n),o.submit(),a.onreadystatechange=function(){"complete"!==a.readystate&&4!==a.readystate||(e(null,a.innerhtml),i.body.removechild(n))},!0},post:function(t,e,n,a){if(this.ie)return this.fpt(t,e,a);if(navigator&&navigator.sendbeacon&&q.test(t)){var o=navigator.sendbeacon(t,e);return a(!o),o}var i;if(r.xdomainrequest)return i=new xdomainrequest,i.open("post",t),i.onload=function(){a(null,i.responsetext)},this.sh(i,"load",function(){a(null,i.responsetext)},!1),this.sh(i,"error",function(){a("post("+t+")error")},!1),this.wrap(!0,i,"onerror",function(r){return function(){return a&&a("post error",i.responsetext),!0}}),i.send(e),!0;if(!p)return!1;i=new p,i.overridemimetype&&i.overridemimetype("text/html");try{i._ty_wrap=1}catch(s){}var c=0;i.onreadystatechange=function(){4==i.readystate&&200==i.status&&(0==c&&a(null,i.responsetext),c++)},i.onerror&&this.wrap(!0,i,"onerror",function(r){return function(){return a("post error",i.responsetext),"function"!=typeof r||r.apply(this,arguments)}});try{i.open("post",t,!0)}catch(s){return this.fpt(t,e,a)}for(var u in n)i.setrequestheader(u,n[u]);return i.send(e),!0},sh:function(r,t,e,n){return r.addeventlistener?r.addeventlistener(t,e,n):!!r.attachevent&&r.attachevent("on"+t,e)},args:function(){for(var r=[],t=0;t=j.server.sr)){var x="ignore_err",w=!(x in j.server)||j.server[x],g=string.prototype.trim;string.prototype.startswith||(string.prototype.startswith=function(r,t){return t=t||0,this.indexof(r,t)===t});var y,z,q=/^http/i,v=function(){function r(){return(65536*(1+math.random())|0).tostring(16).substring(1)}return r()+"-"+r()+r()}(),k=function(){function r(r){return r<0?nan:r<=30?0|math.random()*(1<0;n>>>=1,a+=a)1&n&&(e=a+e);return e}return function(){return t(r(32),8)+"-"+t(r(16),4)+"-"+t(16384|r(12),4)+"-"+t(32768|r(14),4)+"-"+t(r(48),12)}}(),rr="ty_distinct_id",tr=function(){try{return localstorage.setitem(v,v),localstorage.removeitem(v),!0}catch(r){return!1}}();tr?(y=f.bind(localstorage.getitem,localstorage),z=f.bind(localstorage.setitem,localstorage)):(y=n,z=a);try{j&&j(r,"define",{get:function(){return d},set:function(r){"function"==typeof r&&(r.amd||r.cmd)?(d=function(){var t=f.args.apply(this,arguments);if(3!==t.length)return r.apply(this,t);var e="string"==typeof t[0]?t[0]:"anonymous";return r.apply(this,u(t,function(r,t,e){var n;try{n=e,d(e),n=r.apply(this,t),m()}catch(a){throw m(),f(a,e)}return n},e))},f.extend(d,r)):d=r},configurable:!0})}catch(er){}var nr=r.performance?r.performance:r.performance;nr&&(f.sh(nr,"resourcetimingbufferfull",function(){var r=nr.getentriesbytype("resource");r&&(j.ra=j.ra.concat(r),nr.clearresourcetimings())},!1),f.sh(nr,"webkitresourcetimingbufferfull",function(){var r=nr.getentriesbytype("resource");r&&(j.ra=j.ra.concat(r),nr.webkitclearresourcetimings())},!1));var ar="_ty_uf_data",or="_ty_first_day";!function(){function t(r){var t=r[or];t?(t=parseint(t),new date(t).todatestring()===(new date).todatestring()?r[o]=!0:r[o]=!1,r[i]=!1):(r[or]=c(),r[o]=!0,r[i]=!0)}function e(r){function t(r,t){if(r=r.replace(/^http(s)?:\/\//,""),r.startswith(t))return!0;var e=$.exec(r),n=$.exec(t);return e&&n?e[2]==n[2]:r.startswith(t)}var e=i.referrer;e&&!t(e,location.host)&&(r[s]=e)}function n(r){var t={};if(r=r||location.href,!r)return t;var e=r.indexof("?");return e>=0&&(r=r.substring(e+1)),r?(f.each(r.split("&"),function(r){var e=r.split("="),n=a(e[0]),o=a(e[1]);n&&o&&(t[n]=o)}),t):t}function a(r){try{return decodeuricomponent(r)}catch(t){}return null}var o="is_first_day",i="is_first_time",s="latest_referrer",u=2592e3,f=f.parsejson(y(ar))||{};t(f),e(f);var l=n(location.search),p=["utm_source","utm_medium","utm_term","utm_content","utm_campaign"];f.each(p,function(r){l[r]&&(f["latest_"+r]=l[r])}),f.pageref=i.referrer||"",f.first_browser_language=navigator.language||navigator.browserlanguage,f[s]=f[s]||"",f.screen_height=r.screen&&r.screen.height,f.screen_width=r.screen&&r.screen.width,z(ar,f.stringify(f),u)}();for(var ir=j.metric={ready:function(){return j.load_time},initend:function(){function r(){ir.sa()}j.end_time||(j.end_time=c(),this._h=setinterval(r,2e3))},send:function(){function t(){function t(r){return n[r]>0?n[r]-a:0}var e={};if(!nr&&(nr=_(),"string"==typeof nr&&(nr=f.parsejson(nr),i(nr))))return e;if(nr&&nr.timing){var n=nr.timing;a=n.navigationstart;var o=t("domainlookupstart"),c=t("domainlookupend"),u=t("redirectstart"),f=t("redirectend"),l=t("connectstart"),p=t("connectend");e={f:t("fetchstart"),qs:t("requeststart"),rs:t("responsestart"),re:t("responseend"),os:t("domcontentloadedeventstart"),oe:t("domcontentloadedeventend"),oi:t("dominteractive"),oc:t("domcomplete"),ls:t("loadeventstart"),le:t("loadeventend"),tus:t("unloadeventstart"),tue:t("unloadeventend")},p-l>0&&(e.cs=l,e.ce=p),c-o>0&&(e.ds=o,e.de=c),(f-u>0||f>0)&&(e.es=u,e.ee=f),0==e.le&&(e.ue=j.load_time-(_()?j.st:a));var h;if(n.msfirstpaint)h=n.msfirstpaint;else if(r.chrome&&chrome.loadtimes){var d=chrome.loadtimes();d&&d.firstpainttime&&(h=1e3*d.firstpainttime)}else j.firstpaint&&(h=j.firstpaint);h&&(e.fp=math.round(h-a)),n.secureconnectionstart&&(e.sl=t("secureconnectionstart"))}else e={t:a,os:j.end_time-a,ls:j.load_time-a,le:j.load_time-a};e.je=ir.errors.length,ir.ct&&(e.ct=ir.ct-a),ir.touch&&(e.fi=ir.touch-a);var m=j.agent||r._ty_rum&&r._ty_rum.agent;return m&&(e.id=s(m.id),e.a=m.a,e.q=m.q,e.tid=s(m.tid),e.n=s(m.n)),e.sh=r.screen&&r.screen.height,e.sw=r.screen&&r.screen.width,e}function e(t){var e=r._ty_rum.c_ra;if(t)for(var n=e.length-1;n>=0;n--)if(t.indexof(e[n].name)>-1)return e[n].xdata;return null}function n(r){function t(r){return f[r]>0?f[r]:0}var n={tr:!1,tt:s(i.title),charset:i.characterset,uf:v()};if(r0?u.ls:j.load_time-a),o=o?f.stringify(o):"";var f=f.mkurl(j.server.beacon,"pf",u);u=c(),0!=o.length&&f.post(f,o,{},g("post"))||f.get(f),this.sended=!0;var l=f.bind(y,this);l(),setinterval(l,1e4),this.sa(1)}catch(p){sr=!0}return!0},sa:function(r){(this.ready()||r)&&(r||(r=!this._last_send||c()-this._last_send>j.snd_du()||j.aa.length>=j.cc()),j.aa.length>0&&r&&(this._last_send=c(),f.post(f.mkurl(j.server.beacon,"xhr"),f.stringify({xhr:j.aa}),{},g("post")),j.aa=[]))},errors:[]},sr=!1,cr=null,ur={},fr=[["load",k],["beforeunload",t],["pagehide",t],["unload",t]],lr=0;lr