function asyncGeneratorStep(B,x,N,M,J,G,E){try{var K=B[G](E),F=K.value}catch(O){N(O);return}K.done?x(F):Promise.resolve(F).then(M,J)}function _asyncToGenerator(B){return function(){var x=this,N=arguments;return new Promise(function(M,J){function G(F){asyncGeneratorStep(K,M,J,G,E,"next",F)}function E(F){asyncGeneratorStep(K,M,J,G,E,"throw",F)}var K=B.apply(x,N);G(void 0)})}}
function _typeof(B){_typeof="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(x){return typeof x}:function(x){return x&&"function"===typeof Symbol&&x.constructor===Symbol&&x!==Symbol.prototype?"symbol":typeof x};return _typeof(B)}var _regenerator;
(function(){var B=function(x){function N(a,b,d,n){b=Object.create((b&&b.prototype instanceof J?b:J).prototype);n=new P(n||[]);b._invoke=O(a,d,n);return b}function M(a,b,d){try{return{type:"normal",arg:a.call(b,d)}}catch(n){return{type:"throw",arg:n}}}function J(){}function G(){}function E(){}function K(a){["next","throw","return"].forEach(function(b){a[b]=function(d){return this._invoke(b,d)}})}function F(a,b){function d(e,t,v,z){e=M(a[e],a,t);if("throw"===e.type)z(e.arg);else{var w=e.arg;return(e=
w.value)&&"object"===_typeof(e)&&D.call(e,"__await")?b.resolve(e.__await).then(function(y){d("next",y,v,z)},function(y){d("throw",y,v,z)}):b.resolve(e).then(function(y){w.value=y;v(w)},function(y){return d("throw",y,v,z)})}}var n;this._invoke=function(e,t){function v(){return new b(function(z,w){d(e,t,z,w)})}return n=n?n.then(v,v):v()}}function O(a,b,d){var n=m;return function(e,t){if(n===q)throw Error("Generator is already running");if(n===c){if("throw"===e)throw t;return S()}d.method=e;for(d.arg=
t;;){if(e=d.delegate)if(e=T(e,d)){if(e===h)continue;return e}if("next"===d.method)d.sent=d._sent=d.arg;else if("throw"===d.method){if(n===m)throw n=c,d.arg;d.dispatchException(d.arg)}else"return"===d.method&&d.abrupt("return",d.arg);n=q;e=M(a,b,d);if("normal"===e.type){n=d.done?c:k;if(e.arg===h)continue;return{value:e.arg,done:d.done}}"throw"===e.type&&(n=c,d.method="throw",d.arg=e.arg)}}}function T(a,b){var d=a.iterator[b.method];if(d===H){b.delegate=null;if("throw"===b.method){if(a.iterator["return"]&&
(b.method="return",b.arg=H,T(a,b),"throw"===b.method))return h;b.method="throw";b.arg=new TypeError("The iterator does not provide a 'throw' method")}return h}d=M(d,a.iterator,b.arg);if("throw"===d.type)return b.method="throw",b.arg=d.arg,b.delegate=null,h;d=d.arg;if(!d)return b.method="throw",b.arg=new TypeError("iterator result is not an object"),b.delegate=null,h;if(d.done)b[a.resultName]=d.value,b.next=a.nextLoc,"return"!==b.method&&(b.method="next",b.arg=H);else return d;b.delegate=null;return h}
function U(a){var b={tryLoc:a[0]};1 in a&&(b.catchLoc=a[1]);2 in a&&(b.finallyLoc=a[2],b.afterLoc=a[3]);this.tryEntries.push(b)}function Q(a){var b=a.completion||{};b.type="normal";delete b.arg;a.completion=b}function P(a){this.tryEntries=[{tryLoc:"root"}];a.forEach(U,this);this.reset(!0)}function R(a){if(a){var b=a[p];if(b)return b.call(a);if("function"===typeof a.next)return a;if(!isNaN(a.length)){var d=-1;b=function e(){for(;++d<a.length;)if(D.call(a,d))return e.value=a[d],e.done=!1,e;e.value=
H;e.done=!0;return e};return b.next=b}}return{next:S}}function S(){return{value:H,done:!0}}var V=Object.prototype,D=V.hasOwnProperty,H,u="function"===typeof Symbol?Symbol:{},p=u.iterator||"@@iterator",r=u.asyncIterator||"@@asyncIterator",l=u.toStringTag||"@@toStringTag";x.wrap=N;var m="suspendedStart",k="suspendedYield",q="executing",c="completed",h={};u={};u[p]=function(){return this};var g=Object.getPrototypeOf;(g=g&&g(g(R([]))))&&g!==V&&D.call(g,p)&&(u=g);var f=E.prototype=J.prototype=Object.create(u);
G.prototype=f.constructor=E;E.constructor=G;E[l]=G.displayName="GeneratorFunction";x.isGeneratorFunction=function(a){return(a="function"===typeof a&&a.constructor)?a===G||"GeneratorFunction"===(a.displayName||a.name):!1};x.mark=function(a){Object.setPrototypeOf?Object.setPrototypeOf(a,E):(a.__proto__=E,l in a||(a[l]="GeneratorFunction"));a.prototype=Object.create(f);return a};x.awrap=function(a){return{__await:a}};K(F.prototype);F.prototype[r]=function(){return this};x.AsyncIterator=F;x.async=function(a,
b,d,n,e){void 0===e&&(e=Promise);var t=new F(N(a,b,d,n),e);return x.isGeneratorFunction(b)?t:t.next().then(function(v){return v.done?v.value:t.next()})};K(f);f[l]="Generator";f[p]=function(){return this};f.toString=function(){return"[object Generator]"};x.keys=function(a){var b=[],d;for(d in a)b.push(d);b.reverse();return function e(){for(;b.length;){var t=b.pop();if(t in a)return e.value=t,e.done=!1,e}e.done=!0;return e}};x.values=R;P.prototype={constructor:P,reset:function(a){this.next=this.prev=
0;this.sent=this._sent=H;this.done=!1;this.delegate=null;this.method="next";this.arg=H;this.tryEntries.forEach(Q);if(!a)for(var b in this)"t"===b.charAt(0)&&D.call(this,b)&&!isNaN(+b.slice(1))&&(this[b]=H)},stop:function(){this.done=!0;var a=this.tryEntries[0].completion;if("throw"===a.type)throw a.arg;return this.rval},dispatchException:function(a){function b(w,y){t.type="throw";t.arg=a;d.next=w;y&&(d.method="next",d.arg=H);return!!y}if(this.done)throw a;for(var d=this,n=this.tryEntries.length-1;0<=
n;--n){var e=this.tryEntries[n],t=e.completion;if("root"===e.tryLoc)return b("end");if(e.tryLoc<=this.prev){var v=D.call(e,"catchLoc"),z=D.call(e,"finallyLoc");if(v&&z){if(this.prev<e.catchLoc)return b(e.catchLoc,!0);if(this.prev<e.finallyLoc)return b(e.finallyLoc)}else if(v){if(this.prev<e.catchLoc)return b(e.catchLoc,!0)}else if(z){if(this.prev<e.finallyLoc)return b(e.finallyLoc)}else throw Error("try statement without catch or finally");}}},abrupt:function(a,b){for(var d=this.tryEntries.length-
1;0<=d;--d){var n=this.tryEntries[d];if(n.tryLoc<=this.prev&&D.call(n,"finallyLoc")&&this.prev<n.finallyLoc){var e=n;break}}e&&("break"===a||"continue"===a)&&e.tryLoc<=b&&b<=e.finallyLoc&&(e=null);d=e?e.completion:{};d.type=a;d.arg=b;return e?(this.method="next",this.next=e.finallyLoc,h):this.complete(d)},complete:function(a,b){if("throw"===a.type)throw a.arg;"break"===a.type||"continue"===a.type?this.next=a.arg:"return"===a.type?(this.rval=this.arg=a.arg,this.method="return",this.next="end"):"normal"===
a.type&&b&&(this.next=b);return h},finish:function(a){for(var b=this.tryEntries.length-1;0<=b;--b){var d=this.tryEntries[b];if(d.finallyLoc===a)return this.complete(d.completion,d.afterLoc),Q(d),h}},"catch":function(a){for(var b=this.tryEntries.length-1;0<=b;--b){var d=this.tryEntries[b];if(d.tryLoc===a){a=d.completion;if("throw"===a.type){var n=a.arg;Q(d)}return n}}throw Error("illegal catch attempt");},delegateYield:function(a,b,d){this.delegate={iterator:R(a),resultName:b,nextLoc:d};"next"===this.method&&
(this.arg=H);return h}};return x}("object"===("undefined"===typeof module?"undefined":_typeof(module))?module.exports:{});try{_regenerator=B}catch(x){Function("r","_regenerator = r")(B)}})();
(function(){function B(u){var p=null;u==seraph_accel.Gen.hr.E_CONTEXT_EXPIRED?p=D("OpSrvCtxExpired","admin.Manage","seraphinite-accelerator"):seraph_accel.Gen.hr.Fail(u)&&(p=H(D("OpSrvErr_%1$08X","admin.Manage","seraphinite-accelerator"),u));return p}function x(){x=_asyncToGenerator(_regenerator.mark(function r(p){return _regenerator.wrap(function(l){for(;;)switch(l.prev=l.next){case 0:return jQuery(p).attr("disabled",!0),l.prev=1,l.next=4,jQuery.ajax({url:seraph_accel.Net.UpdateQueryArgs(seraph_accel.Plugin.GetAdminApiUrl()+
"LogClear",{}),type:"POST",data:"",dataType:"json",cache:!1});case 4:l.next=8;break;case 6:l.prev=6,l.t0=l["catch"](1);case 8:jQuery(p).attr("disabled",!1);case 9:case "end":return l.stop()}},r,this,[[1,6]])}));return x.apply(this,arguments)}function N(){N=_asyncToGenerator(_regenerator.mark(function l(p,r){var m,k,q,c,h,g;return _regenerator.wrap(function(f){for(;;)switch(f.prev=f.next){case 0:m=jQuery(p.parentNode).closest(".blck").first();k=m.find(".seraph_accel_spinner");m.find(".content");q=
m.find('input[type="button"]:not(.cancel)');c=m.find('input[type="button"].cancel');if(!r){f.next=23;break}q.prop("disabled",!0);k.show();seraph_accel.Manager._int.notRefreshStat=!0;h=null;f.prev=10;f.next=13;return jQuery.ajax({url:seraph_accel.Net.UpdateQueryArgs(seraph_accel.Plugin.GetAdminApiUrl()+"UpdateStatBegin",{}),cache:!1,dataType:"json"});case 13:g=f.sent;seraph_accel.Gen.hr.Fail(g)&&(h=H(D("OpSrvErr_%1$08X","admin.Manage","seraphinite-accelerator"),g));f.next=20;break;case 17:f.prev=17,
f.t0=f["catch"](10),h="HTTP "+f.t0.status;case 20:return h&&(alert(h),q.prop("disabled",!1),k.hide()),delete seraph_accel.Manager._int.notRefreshStat,f.abrupt("return");case 23:return c.prop("disabled",!0),seraph_accel.Manager._int.notRefreshStat=!0,h=null,f.prev=26,f.next=29,jQuery.ajax({url:seraph_accel.Net.UpdateQueryArgs(seraph_accel.Plugin.GetAdminApiUrl()+"UpdateStatCancel",{}),type:"POST",data:"",cache:!1,dataType:"json"});case 29:g=f.sent;h=B(g);f.next=37;break;case 33:f.prev=33,f.t1=f["catch"](26),
h="HTTP "+f.t1.status,c.prop("disabled",!1);case 37:h&&alert(h),delete seraph_accel.Manager._int.notRefreshStat;case 39:case "end":return f.stop()}},l,this,[[10,17],[26,33]])}));return N.apply(this,arguments)}function M(u){switch(u){case 0:return D("OpDescr_Invalidate","admin.Manage","seraphinite-accelerator");case 3:return D("OpDescr_CheckInvalidate","admin.Manage","seraphinite-accelerator");case 2:return D("OpDescr_Delete","admin.Manage","seraphinite-accelerator");case 10:return D("OpDescr_SrvDel",
"admin.Manage","seraphinite-accelerator")}return""+u}function J(){J=_asyncToGenerator(_regenerator.mark(function r(p){var l,m,k,q;return _regenerator.wrap(function(c){for(;;)switch(c.prev=c.next){case 0:return l=jQuery(p.parentNode).closest(".blck").first(),m=l.find('input[type="button"].cancel'),m.prop("disabled",!0),k=null,c.prev=4,c.next=7,jQuery.ajax({url:seraph_accel.Net.UpdateQueryArgs(seraph_accel.Plugin.GetAdminApiUrl()+"PostUpdCancel",{}),type:"POST",data:"",cache:!1,dataType:"json"});case 7:q=
c.sent;k=B(q);c.next=14;break;case 11:c.prev=11,c.t0=c["catch"](4),k="HTTP "+c.t0.status;case 14:k&&alert(k);case 15:case "end":return c.stop()}},r,this,[[4,11]])}));return J.apply(this,arguments)}function G(){G=_asyncToGenerator(_regenerator.mark(function r(p){var l,m,k,q;return _regenerator.wrap(function(c){for(;;)switch(c.prev=c.next){case 0:return l=jQuery(p.parentNode).closest(".blck").first(),m=l.find('input[type="button"].cancel'),m.prop("disabled",!0),k=null,c.prev=4,c.next=7,jQuery.ajax({url:seraph_accel.Net.UpdateQueryArgs(seraph_accel.Plugin.GetAdminApiUrl()+
"ScheUpdCancel",{}),type:"POST",data:"",cache:!1,dataType:"json"});case 7:q=c.sent;k=B(q);c.next=14;break;case 11:c.prev=11,c.t0=c["catch"](4),k="HTTP "+c.t0.status;case 14:k&&alert(k);case 15:case "end":return c.stop()}},r,this,[[4,11]])}));return G.apply(this,arguments)}function E(){E=_asyncToGenerator(_regenerator.mark(function r(p){var l,m,k,q,c,h;return _regenerator.wrap(function(g){for(;;)switch(g.prev=g.next){case 0:return l=jQuery(p.parentNode).closest(".blck").first(),m=l.find(".seraph_accel_spinner"),
k=l.find('input[type="button"]:not(.cancel)'),q=l.find('input[type="button"].cancel'),m.show(),k.prop("disabled",!0),q.prop("disabled",!1),seraph_accel.Manager._int.notRefreshExtDp=!0,c=null,g.prev=9,g.next=12,jQuery.ajax({url:seraph_accel.Net.UpdateQueryArgs(seraph_accel.Plugin.GetAdminApiUrl()+"ExtDbUpdBegin",{}),type:"POST",data:"",cache:!1,dataType:"json"});case 12:h=g.sent;c=B(h);g.next=19;break;case 16:g.prev=16,g.t0=g["catch"](9),c="HTTP "+g.t0.status;case 19:c&&alert(c),delete seraph_accel.Manager._int.notRefreshExtDp;
case 21:case "end":return g.stop()}},r,this,[[9,16]])}));return E.apply(this,arguments)}function K(){K=_asyncToGenerator(_regenerator.mark(function r(p){var l,m,k,q;return _regenerator.wrap(function(c){for(;;)switch(c.prev=c.next){case 0:return l=jQuery(p.parentNode).closest(".blck").first(),m=l.find('input[type="button"].cancel'),m.prop("disabled",!0),k=null,c.prev=4,c.next=7,jQuery.ajax({url:seraph_accel.Net.UpdateQueryArgs(seraph_accel.Plugin.GetAdminApiUrl()+"ExtDbUpdCancel",{}),type:"POST",data:"",
cache:!1,dataType:"json"});case 7:q=c.sent;k=B(q);c.next=14;break;case 11:c.prev=11,c.t0=c["catch"](4),k="HTTP "+c.t0.status;case 14:k&&alert(k);case 15:case "end":return c.stop()}},r,this,[[4,11]])}));return K.apply(this,arguments)}function F(){F=_asyncToGenerator(_regenerator.mark(function m(p,r,l){var k,q,c,h,g,f,a,b,d,n,e,t,v,z,w,y;return _regenerator.wrap(function(A){for(;;)switch(A.prev=A.next){case 0:return k=jQuery(p.parentNode).closest(".blck").first(),q=k.find(".seraph_accel_spinner"),c=
k.find(".descr"),h=k.find('input[type="button"]:not(.cancel)'),g=k.find('input[type="button"].cancel'),f=k.find("#seraph_accel_views"),a=k.find("#seraph_accel_geos"),b=k.find("#seraph_accel_langs"),d=[],f.get()&&(seraph_accel.Ui.TokensMetaTree.Apply(f.get()),d=seraph_accel.Ui.TokensList.GetVal(f.get())),n=[],a.get()&&(seraph_accel.Ui.TokensMetaTree.Apply(a.get()),n=seraph_accel.Ui.TokensList.GetVal(a.get()).filter(function(I){return"_"!==I})),e=[],b.get()&&(seraph_accel.Ui.TokensMetaTree.Apply(b.get()),
e=seraph_accel.Ui.TokensList.GetVal(b.get())),v=String(k.find(".type").val()),"uri"===v?t=k.find(".uri").val():0===v.indexOf("uri:")&&(t=v.substr(4),v="uri"),t="string"==typeof t?seraph_accel.Gen.StrReplaceAll(t,["\r","\n","*"],["",";","{ASTRSK}"]):"",q.show(),c.show(),c.text(M(r)),h.prop("disabled",!0),g.prop("disabled",!1),seraph_accel.Manager._int.notRefreshOp=!0,z={cache:!1,dataType:"json"},512>t.length?z.url=seraph_accel.Net.UpdateQueryArgs(seraph_accel.Plugin.GetAdminApiUrl()+"CacheOpBegin",
{type:v,op:r,uri:t,v:d.join(),g:n.length?n.join():void 0,l:e.length?e.join():void 0,_wpnonce:l}):(z.url=seraph_accel.Net.UpdateQueryArgs(seraph_accel.Plugin.GetAdminApiUrl()+"CacheOpBegin",{type:v,op:r,v:d.join(),g:n.length?n.join():void 0,l:e.length?e.join():void 0,_wpnonce:l}),z.type="POST",z.contentType="application/x-www-form-urlencoded",z.data="uri="+encodeURIComponent(t)),w=null,A.prev=26,A.next=29,jQuery.ajax(z);case 29:y=A.sent;w=B(y);A.next=36;break;case 33:A.prev=33,A.t0=A["catch"](26),
w="HTTP "+A.t0.status;case 36:w&&alert(w),delete seraph_accel.Manager._int.notRefreshOp;case 38:case "end":return A.stop()}},m,this,[[26,33]])}));return F.apply(this,arguments)}function O(){O=_asyncToGenerator(_regenerator.mark(function m(p,r,l){var k,q,c,h;return _regenerator.wrap(function(g){for(;;)switch(g.prev=g.next){case 0:return k=jQuery(p.parentNode).closest(".blck").first(),q=k.find('input[type="button"].cancel'),q.prop("disabled",!0),c=null,g.prev=4,g.next=7,jQuery.ajax({url:seraph_accel.Net.UpdateQueryArgs(seraph_accel.Plugin.GetAdminApiUrl()+
"CacheOpCancel",{op:r,_wpnonce:l}),type:"POST",data:"",cache:!1,dataType:"json"});case 7:h=g.sent;c=B(h);g.next=14;break;case 11:g.prev=11,g.t0=g["catch"](4),c="HTTP "+g.t0.status;case 14:c&&alert(c);case 15:case "end":return g.stop()}},m,this,[[4,11]])}));return O.apply(this,arguments)}function T(){T=_asyncToGenerator(_regenerator.mark(function m(p,r,l){var k,q,c,h,g;return _regenerator.wrap(function(f){for(;;)switch(f.prev=f.next){case 0:return k=jQuery(p.parentNode).closest(".blck").first(),q=
k.find(".seraph_accel_spinner"),c=k.find('input[type="button"]'),q.show(),c.prop("disabled",!0),seraph_accel.Manager._int.notRefreshQueueDeleting=!0,h=null,f.prev=7,f.next=10,jQuery.ajax({url:seraph_accel.Net.UpdateQueryArgs(seraph_accel.Plugin.GetAdminApiUrl()+"QueueDelete",{allSites:r?!0:void 0,_wpnonce:l}),type:"GET",cache:!1,dataType:"json"});case 10:g=f.sent;h=B(g);f.next=17;break;case 14:f.prev=14,f.t0=f["catch"](7),h="HTTP "+f.t0.status;case 17:h&&(alert(h),q.hide(),c.prop("disabled",!1)),
delete seraph_accel.Manager._int.notRefreshQueueDeleting;case 19:case "end":return f.stop()}},m,this,[[7,14]])}));return T.apply(this,arguments)}function U(){U=_asyncToGenerator(_regenerator.mark(function m(p,r,l){var k,q,c,h,g;return _regenerator.wrap(function(f){for(;;)switch(f.prev=f.next){case 0:return k=jQuery(p.parentNode).closest(".blck").first(),q=k.find(".seraph_accel_spinner"),c=k.find('input[type="button"]'),q.show(),c.prop("disabled",!0),seraph_accel.Manager._int.notRefreshQueueDeleting=
!0,h=null,f.prev=7,f.next=10,jQuery.ajax({url:seraph_accel.Net.UpdateQueryArgs(seraph_accel.Plugin.GetAdminApiUrl()+"QueuePause",{v:r,_wpnonce:l}),type:"POST",cache:!1,dataType:"json"});case 10:g=f.sent;h=B(g);f.next=17;break;case 14:f.prev=14,f.t0=f["catch"](7),h="HTTP "+f.t0.status;case 17:h&&(alert(h),q.hide(),c.prop("disabled",!1)),delete seraph_accel.Manager._int.notRefreshQueueDeleting;case 19:case "end":return f.stop()}},m,this,[[7,14]])}));return U.apply(this,arguments)}function Q(){Q=_asyncToGenerator(_regenerator.mark(function m(p,
r,l){var k,q,c,h,g;return _regenerator.wrap(function(f){for(;;)switch(f.prev=f.next){case 0:if(confirm(D("ItemCancelConfirm","admin.Manage_Queue","seraphinite-accelerator"))){f.next=2;break}return f.abrupt("return");case 2:return k=jQuery(p.parentNode).closest(".blck").first(),q=k.find(".seraph_accel_spinner"),c=k.find('input[type="button"]'),q.show(),c.prop("disabled",!0),seraph_accel.Manager._int.notRefreshQueueDeleting=!0,h=null,f.prev=9,f.next=12,jQuery.ajax({url:seraph_accel.Net.UpdateQueryArgs(seraph_accel.Plugin.GetAdminApiUrl()+
"QueueItemCancel",{pc:r,_wpnonce:l}),type:"GET",cache:!1,dataType:"json"});case 12:g=f.sent;h=B(g);f.next=19;break;case 16:f.prev=16,f.t0=f["catch"](9),h="HTTP "+f.t0.status;case 19:h&&alert(h),q.hide(),c.prop("disabled",!1),delete seraph_accel.Manager._int.notRefreshQueueDeleting;case 23:case "end":return f.stop()}},m,this,[[9,16]])}));return Q.apply(this,arguments)}function P(){P=_asyncToGenerator(_regenerator.mark(function l(p,r){var m,k,q,c;return _regenerator.wrap(function(h){for(;;)switch(h.prev=
h.next){case 0:c=function(){c=_asyncToGenerator(_regenerator.mark(function f(){return _regenerator.wrap(function(a){for(;;)switch(a.prev=a.next){case 0:return a.next=2,seraph_accel.Manager._int.OnDataRefresh(p,r);case 2:k();case 3:case "end":return a.stop()}},f,this)}));return c.apply(this,arguments)},q=function(){return c.apply(this,arguments)},k=function(){var g=1E3*parseInt(m.val(),10);100>g&&(g=100);clearTimeout(seraph_accel.Manager._int.refreshTimer);seraph_accel.Manager._int.refreshTimer=setTimeout(q,
g)},m=jQuery(p).find("#operate .tmDataRefresh"),m.on("change",k),q();case 6:case "end":return h.stop()}},l,this)}));return P.apply(this,arguments)}function R(){R=_asyncToGenerator(_regenerator.mark(function l(p,r){var m,k,q,c,h,g,f,a,b,d,n,e,t,v,z,w,y,A,I,C,W;return _regenerator.wrap(function(L){for(;;)switch(L.prev=L.next){case 0:return m=jQuery(p).find("#status").first(),k=jQuery(p).find("#stat").first(),q=k.find(".seraph_accel_spinner"),c=k.find('input[type="button"]:not(.cancel)'),h=k.find('input[type="button"].cancel'),
g=jQuery(p).find("#operate").first(),f=g.find(".seraph_accel_spinner"),a=g.find(".descr"),b=g.find('input[type="button"]:not(.cancel)'),d=g.find('input[type="button"].cancel'),n=jQuery(p).find("#queue").first(),e=n.find(".content"),t=n.find(".maxItems"),v=n.find(".seraph_accel_spinner"),z=n.find('input[type="button"]'),w=n.find(".descrNums"),L.prev=16,L.next=19,jQuery.ajax({url:seraph_accel.Net.UpdateQueryArgs(seraph_accel.Plugin.GetAdminApiUrl()+"GetData",{nMaxQueueItems:t.val(),allSites:r?!0:void 0}),
type:"GET",cache:!1,dataType:"json"});case 19:C=L.sent;L.next=24;break;case 22:L.prev=22,L.t0=L["catch"](16);case 24:if(C){L.next=26;break}return L.abrupt("return");case 26:if(!r){for(W in C.status.cont)m.find('[data-id-cont="'+W+'"]').html(C.status.cont[W]);seraph_accel.Manager._int.notRefreshPostUpd||(y=m.find(".blck.postupd .seraph_accel_spinner"),A=m.find('.blck.postupd input[type="button"]:not(.cancel)'),I=m.find('.blck.postupd input[type="button"].cancel'),C.status.postUpd?(y.show(),A.prop("disabled",
!0),I.prop("disabled",!1)):(y.hide(),A.prop("disabled",!1),I.prop("disabled",!0)));seraph_accel.Manager._int.notRefreshScheUpd||(y=m.find(".blck.scheupd .seraph_accel_spinner"),A=m.find('.blck.scheupd input[type="button"]:not(.cancel)'),I=m.find('.blck.scheupd input[type="button"].cancel'),C.status.scheUpd?(y.show(),A.prop("disabled",!0),I.prop("disabled",!1)):(y.hide(),A.prop("disabled",!1),I.prop("disabled",!0)));seraph_accel.Manager._int.notRefreshCleanup||(y=m.find(".blck.cleanup .seraph_accel_spinner"),
A=m.find('.blck.cleanup input[type="button"]:not(.cancel)'),I=m.find('.blck.cleanup input[type="button"].cancel'),C.status.cleanUp?(y.show(),A.prop("disabled",!0),I.prop("disabled",!1)):(y.hide(),A.prop("disabled",!1),I.prop("disabled",!0)))}r||seraph_accel.Manager._int.notRefreshExtDp||(y=m.find(".blck.extdb .seraph_accel_spinner"),A=m.find('.blck.extdb input[type="button"]:not(.cancel)'),I=m.find('.blck.extdb input[type="button"].cancel'),C.extDb.isUpdating?(y.show(),A.prop("disabled",!0),I.prop("disabled",
!1)):(y.hide(),A.prop("disabled",!1),I.prop("disabled",!0)));r||seraph_accel.Manager._int.notRefreshStat||(C.stat.isUpdating?(q.show(),c.prop("disabled",!0),h.prop("disabled",!1)):(q.hide(),c.prop("disabled",!1),h.prop("disabled",!0)),k.find('[data-id-cont="stat"]').html(C.stat.cont));r||seraph_accel.Manager._int.notRefreshOp||(null===C.curOp&&(C.curOp=void 0),void 0!==C.curOp?(f.show(),a.show(),a.text(M(C.curOp)),b.prop("disabled",!0),d.prop("disabled",!1)):(f.hide(),a.hide(),b.prop("disabled",!1),
d.prop("disabled",!0),a.text("")));e.html(C.queue.content);w.text(H(D("QueueNumsDescr_%1$u%2$u","admin.Manage","seraphinite-accelerator"),C.queue.nums.nInitial,C.queue.nums.nInProgress));seraph_accel.Manager._int.notRefreshQueueDeleting||(v.hide(),z.prop("disabled",!1),C.queue.isPaused?(n.find('input[type="button"].pause').hide(),n.find('input[type="button"].resume').show()):(n.find('input[type="button"].pause').show(),n.find('input[type="button"].resume').hide()));case 33:case "end":return L.stop()}},
l,this,[[16,22]])}));return R.apply(this,arguments)}function S(){S=_asyncToGenerator(_regenerator.mark(function r(p){var l,m,k,q,c,h,g,f;return _regenerator.wrap(function(a){for(;;)switch(a.prev=a.next){case 0:return l=jQuery(p.parentNode).closest(".blck").first(),m=l.find(".url"),k=l.find(".messages"),q=l.find(".seraph_accel_spinner"),c=l.find('input[type="button"]'),h=0,l.find(".liteChk").prop("checked")&&(h|=1),l.find(".medChk").prop("checked")&&(h|=2),l.find(".tidyChk").prop("checked")&&(h|=524288),
k.empty(),q.show(),c.prop("disabled",!0),a.prev=12,a.next=15,jQuery.ajax({url:seraph_accel.Net.UpdateQueryArgs(seraph_accel.Plugin.GetAdminApiUrl()+"HtmlCheck",{url:m.val(),norm:h}),type:"POST",data:"",dataType:"json",cache:!1});case 15:g=a.sent;a.next=21;break;case 18:a.prev=18,a.t0=a["catch"](12),g={err:a.t0.statusText};case 21:q.hide();c.prop("disabled",!1);if(!g.err){a.next=26;break}k.append(seraph_accel.Ui.LogItem("error",g.err));return a.abrupt("return");case 26:for(f in g.list)f=g.list[f],
k.append(seraph_accel.Ui.LogItem(f.severity,f.text));case 27:case "end":return a.stop()}},r,this,[[12,18]])}));return S.apply(this,arguments)}var V=seraph_accel.Wp.Loc.GetApi(),D=V._x,H=V.sprintf;seraph_accel.Settings={_int:{OnUpdateCssAuto:function(u){seraph_accel.Ui.ComboShowDependedItems(u,jQuery(u.parentNode).closest(".blck").first().get(0))},OnLogClear:function(u){return x.apply(this,arguments)}}};seraph_accel.Manager={_int:{OnStatOp:function(u,p){return N.apply(this,arguments)},OnCacheOp:function(u,
p,r){return F.apply(this,arguments)},OnCacheOpCancel:function(u,p,r){return O.apply(this,arguments)},OnPostUpdCancel:function(u){return J.apply(this,arguments)},OnScheUpdCancel:function(u){return G.apply(this,arguments)},OnExtDbUpdBegin:function(u){return E.apply(this,arguments)},OnExtDbUpdCancel:function(u){return K.apply(this,arguments)},OnQueueDel:function(u,p,r){return T.apply(this,arguments)},OnQueuePause:function(u,p,r){return U.apply(this,arguments)},OnQueueItemCancel:function(u,p,r){return Q.apply(this,
arguments)},OnDataRefreshInit:function(u,p){return P.apply(this,arguments)},OnDataRefresh:function(u,p){return R.apply(this,arguments)},OnHtmlCheck:function(u){return S.apply(this,arguments)}}};(function(){function u(m){return p.apply(this,arguments)}function p(){p=_asyncToGenerator(_regenerator.mark(function q(k){var c,h;return _regenerator.wrap(function(g){for(;;)switch(g.prev=g.next){case 0:return c={},g.prev=1,seraph_accel.SelfDiag._int.curAjax=jQuery.ajax({url:seraph_accel.Net.UpdateQueryArgs(seraph_accel.Plugin.GetAdminApiUrl()+
"SelfDiag_"+k,{}),cache:!1,dataType:"json"}),g.next=5,seraph_accel.SelfDiag._int.curAjax;case 5:c=g.sent;delete seraph_accel.SelfDiag._int.curAjax;g.next=14;break;case 9:g.prev=9,g.t0=g["catch"](1),delete seraph_accel.SelfDiag._int.curAjax,0===g.t0.status?c.hr=seraph_accel.Gen.hr.S_ABORTED:(c.hr=seraph_accel.Gen.hr.E_FAIL,c.descr="HTTP "+g.t0.status),500==g.t0.status&&(h=document.implementation.createHTMLDocument(""),h.documentElement.innerHTML=g.t0.responseText,h=h.body.textContent,h=seraph_accel.Gen.StrReplaceAll(h,
"\r",""),h=seraph_accel.Gen.StrReplaceAll(h,["\t","\v"]," "),h=seraph_accel.Gen.StrReplaceAll(h,"\n",". "),(h=seraph_accel.Gen.StrReplaceAllWhileChanging(h,["  ",". . "],[" ",". "]).trim())&&"."!=h&&(c.descr+="<br>"+h));case 14:return g.abrupt("return",c);case 15:case "end":return g.stop()}},q,this,[[1,9]])}));return p.apply(this,arguments)}function r(){r=_asyncToGenerator(_regenerator.mark(function q(k){var c,h,g,f,a,b,d,n,e,t,v,z=arguments;return _regenerator.wrap(function(w){for(;;)switch(w.prev=
w.next){case 0:c=1<z.length&&void 0!==z[1]?z[1]:!1;h=jQuery(k.parentNode).closest(".blck").first();g=h.find(".seraph_accel_spinner");f=h.find('input[type="button"]:not(.cancel)');a=h.find('input[type="button"].cancel');b=h.find(".log");d=[{id:"3rdPartySettCompat",name:l("TestName_3rdPartySettCompat","admin.SelfDiag","seraphinite-accelerator")},{id:"AsyncRequest",name:l("TestName_AsyncRequest","admin.SelfDiag","seraphinite-accelerator")},{id:"SetMaxExecTime",name:l("TestName_SetMaxExecTime","admin.SelfDiag",
"seraphinite-accelerator")},{id:"PageOptimize",name:l("TestName_PageOptimize","admin.SelfDiag","seraphinite-accelerator")},{id:"VendorSrv",name:l("TestName_VendorSrv","admin.SelfDiag","seraphinite-accelerator")},{id:"ExtCache",name:l("TestName_ExtCache","admin.SelfDiag","seraphinite-accelerator")}];b.empty();for(n=0;n<d.length;n++)e=d[n],b.append(seraph_accel.Ui.LogItem("none",seraph_accel.Ui.Tag("strong",e.name?e.name:e.id),!1));if(!c){w.next=11;break}return w.abrupt("return");case 11:g.show(),f.prop("disabled",
!0),a.prop("disabled",!1),seraph_accel.SelfDiag._int.inProgress=!0,n=0;case 16:if(!(n<d.length)){w.next=31;break}e=d[n];jQuery(b.children().get(n)).replaceWith(seraph_accel.Ui.LogItem("info",seraph_accel.Ui.Tag("strong",e.name?e.name:e.id)+l("TestRunning","admin.SelfDiag","seraphinite-accelerator"),!1));w.next=21;return u(e.id);case 21:t=w.sent;v=l("TestSucc","admin.SelfDiag","seraphinite-accelerator");t.hr!=seraph_accel.Gen.hr.S_OK&&(v=seraph_accel.Gen.hr.Succ(t.hr)?t.hr==seraph_accel.Gen.hr.S_ABORTED?
l("TestAbort","admin.SelfDiag","seraphinite-accelerator"):t.hr==seraph_accel.Gen.hr.S_FALSE?l("TestNotice","admin.SelfDiag","seraphinite-accelerator"):l("TestWarn","admin.SelfDiag","seraphinite-accelerator"):l("TestError","admin.SelfDiag","seraphinite-accelerator"));t.descr&&(v+="<br>"+t.descr);jQuery(b.children().get(n)).replaceWith(seraph_accel.Ui.LogItem(t.hr==seraph_accel.Gen.hr.S_OK?"success":seraph_accel.Gen.hr.Succ(t.hr)?t.hr==seraph_accel.Gen.hr.S_FALSE?"normal":"warning":"error",seraph_accel.Ui.Tag("strong",
e.name?e.name:e.id)+v,!1));if(seraph_accel.SelfDiag._int.inProgress){w.next=28;break}return w.abrupt("break",31);case 28:n++;w.next=16;break;case 31:g.hide(),f.prop("disabled",!1),a.prop("disabled",!0);case 34:case "end":return w.stop()}},q,this)}));return r.apply(this,arguments)}var l=seraph_accel.Wp.Loc.GetApi()._x;seraph_accel.SelfDiag={_int:{OnStart:function(m){return r.apply(this,arguments)},OnCancel:function(m){m=jQuery(m.parentNode).closest(".blck").first();m.find(".seraph_accel_spinner");
m.find('input[type="button"]:not(.cancel)');m.find('input[type="button"].cancel').prop("disabled",!0);seraph_accel.SelfDiag._int.inProgress=!1;seraph_accel.SelfDiag._int.curAjax&&seraph_accel.SelfDiag._int.curAjax.abort()},inProgress:!1}}})()})();
