New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

object-delete-key

Package Overview
Dependencies
Maintainers
1
Versions
192
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

object-delete-key - npm Package Compare versions

Comparing version 1.8.21 to 1.8.22

2

dist/object-delete-key.cjs.js
/**
* object-delete-key
* Delete keys from all arrays or plain objects, nested within anything, by key or by value or by both, and clean up afterwards. Accepts wildcards.
* Version: 1.8.21
* Version: 1.8.22
* Author: Roy Revelt, Codsen Ltd

@@ -6,0 +6,0 @@ * License: MIT

/**
* object-delete-key
* Delete keys from all arrays or plain objects, nested within anything, by key or by value or by both, and clean up afterwards. Accepts wildcards.
* Version: 1.8.21
* Version: 1.8.22
* Author: Roy Revelt, Codsen Ltd

@@ -6,0 +6,0 @@ * License: MIT

/**
* object-delete-key
* Delete keys from all arrays or plain objects, nested within anything, by key or by value or by both, and clean up afterwards. Accepts wildcards.
* Version: 1.8.21
* Version: 1.8.22
* Author: Roy Revelt, Codsen Ltd

@@ -10,2 +10,2 @@ * License: MIT

!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e=e||self).objectDeleteKey=t()}(this,function(){"use strict";var e="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function t(e,t){return e(t={exports:{}},t.exports),t.exports}var r=t(function(t,r){var n=200,o="__lodash_hash_undefined__",i=9007199254740991,a="[object Arguments]",u="[object Boolean]",c="[object Date]",s="[object Function]",f="[object GeneratorFunction]",l="[object Map]",y="[object Number]",h="[object Object]",p="[object RegExp]",g="[object Set]",d="[object String]",v="[object Symbol]",b="[object ArrayBuffer]",m="[object DataView]",j="[object Float32Array]",_="[object Float64Array]",w="[object Int8Array]",O="[object Int16Array]",$="[object Int32Array]",S="[object Uint8Array]",k="[object Uint8ClampedArray]",A="[object Uint16Array]",T="[object Uint32Array]",N=/\w*$/,x=/^\[object .+?Constructor\]$/,E=/^(?:0|[1-9]\d*)$/,W={};W[a]=W["[object Array]"]=W[b]=W[m]=W[u]=W[c]=W[j]=W[_]=W[w]=W[O]=W[$]=W[l]=W[y]=W[h]=W[p]=W[g]=W[d]=W[v]=W[S]=W[k]=W[A]=W[T]=!0,W["[object Error]"]=W[s]=W["[object WeakMap]"]=!1;var I="object"==typeof e&&e&&e.Object===Object&&e,P="object"==typeof self&&self&&self.Object===Object&&self,M=I||P||Function("return this")(),D=r&&!r.nodeType&&r,F=D&&t&&!t.nodeType&&t,J=F&&F.exports===D;function R(e,t){return e.set(t[0],t[1]),e}function C(e,t){return e.add(t),e}function V(e,t,r,n){var o=-1,i=e?e.length:0;for(n&&i&&(r=e[++o]);++o<i;)r=t(r,e[o],o,e);return r}function H(e){var t=!1;if(null!=e&&"function"!=typeof e.toString)try{t=!!(e+"")}catch(e){}return t}function L(e){var t=-1,r=Array(e.size);return e.forEach(function(e,n){r[++t]=[n,e]}),r}function K(e,t){return function(r){return e(t(r))}}function q(e){var t=-1,r=Array(e.size);return e.forEach(function(e){r[++t]=e}),r}var Z,B=Array.prototype,U=Function.prototype,G=Object.prototype,z=M["__core-js_shared__"],Q=(Z=/[^.]+$/.exec(z&&z.keys&&z.keys.IE_PROTO||""))?"Symbol(src)_1."+Z:"",X=U.toString,Y=G.hasOwnProperty,ee=G.toString,te=RegExp("^"+X.call(Y).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),re=J?M.Buffer:void 0,ne=M.Symbol,oe=M.Uint8Array,ie=K(Object.getPrototypeOf,Object),ae=Object.create,ue=G.propertyIsEnumerable,ce=B.splice,se=Object.getOwnPropertySymbols,fe=re?re.isBuffer:void 0,le=K(Object.keys,Object),ye=Fe(M,"DataView"),he=Fe(M,"Map"),pe=Fe(M,"Promise"),ge=Fe(M,"Set"),de=Fe(M,"WeakMap"),ve=Fe(Object,"create"),be=He(ye),me=He(he),je=He(pe),_e=He(ge),we=He(de),Oe=ne?ne.prototype:void 0,$e=Oe?Oe.valueOf:void 0;function Se(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function ke(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function Ae(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function Te(e){this.__data__=new ke(e)}function Ne(e,t){var r=Ke(e)||function(e){return function(e){return function(e){return!!e&&"object"==typeof e}(e)&&qe(e)}(e)&&Y.call(e,"callee")&&(!ue.call(e,"callee")||ee.call(e)==a)}(e)?function(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}(e.length,String):[],n=r.length,o=!!n;for(var i in e)!t&&!Y.call(e,i)||o&&("length"==i||Ce(i,n))||r.push(i);return r}function xe(e,t,r){var n=e[t];Y.call(e,t)&&Le(n,r)&&(void 0!==r||t in e)||(e[t]=r)}function Ee(e,t){for(var r=e.length;r--;)if(Le(e[r][0],t))return r;return-1}function We(e,t,r,n,o,i,x){var E;if(n&&(E=i?n(e,o,i,x):n(e)),void 0!==E)return E;if(!Ue(e))return e;var I=Ke(e);if(I){if(E=function(e){var t=e.length,r=e.constructor(t);t&&"string"==typeof e[0]&&Y.call(e,"index")&&(r.index=e.index,r.input=e.input);return r}(e),!t)return function(e,t){var r=-1,n=e.length;t||(t=Array(n));for(;++r<n;)t[r]=e[r];return t}(e,E)}else{var P=Re(e),M=P==s||P==f;if(Ze(e))return function(e,t){if(t)return e.slice();var r=new e.constructor(e.length);return e.copy(r),r}(e,t);if(P==h||P==a||M&&!i){if(H(e))return i?e:{};if(E=function(e){return"function"!=typeof e.constructor||Ve(e)?{}:(t=ie(e),Ue(t)?ae(t):{});var t}(M?{}:e),!t)return function(e,t){return Me(e,Je(e),t)}(e,function(e,t){return e&&Me(t,Ge(t),e)}(E,e))}else{if(!W[P])return i?e:{};E=function(e,t,r,n){var o=e.constructor;switch(t){case b:return Pe(e);case u:case c:return new o(+e);case m:return function(e,t){var r=t?Pe(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.byteLength)}(e,n);case j:case _:case w:case O:case $:case S:case k:case A:case T:return function(e,t){var r=t?Pe(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.length)}(e,n);case l:return function(e,t,r){return V(t?r(L(e),!0):L(e),R,new e.constructor)}(e,n,r);case y:case d:return new o(e);case p:return(s=new(a=e).constructor(a.source,N.exec(a))).lastIndex=a.lastIndex,s;case g:return function(e,t,r){return V(t?r(q(e),!0):q(e),C,new e.constructor)}(e,n,r);case v:return i=e,$e?Object($e.call(i)):{}}var i;var a,s}(e,P,We,t)}}x||(x=new Te);var D=x.get(e);if(D)return D;if(x.set(e,E),!I)var F=r?function(e){return function(e,t,r){var n=t(e);return Ke(e)?n:function(e,t){for(var r=-1,n=t.length,o=e.length;++r<n;)e[o+r]=t[r];return e}(n,r(e))}(e,Ge,Je)}(e):Ge(e);return function(e,t){for(var r=-1,n=e?e.length:0;++r<n&&!1!==t(e[r],r,e););}(F||e,function(o,i){F&&(o=e[i=o]),xe(E,i,We(o,t,r,n,i,e,x))}),E}function Ie(e){return!(!Ue(e)||(t=e,Q&&Q in t))&&(Be(e)||H(e)?te:x).test(He(e));var t}function Pe(e){var t=new e.constructor(e.byteLength);return new oe(t).set(new oe(e)),t}function Me(e,t,r,n){r||(r={});for(var o=-1,i=t.length;++o<i;){var a=t[o],u=n?n(r[a],e[a],a,r,e):void 0;xe(r,a,void 0===u?e[a]:u)}return r}function De(e,t){var r,n,o=e.__data__;return("string"==(n=typeof(r=t))||"number"==n||"symbol"==n||"boolean"==n?"__proto__"!==r:null===r)?o["string"==typeof t?"string":"hash"]:o.map}function Fe(e,t){var r=function(e,t){return null==e?void 0:e[t]}(e,t);return Ie(r)?r:void 0}Se.prototype.clear=function(){this.__data__=ve?ve(null):{}},Se.prototype.delete=function(e){return this.has(e)&&delete this.__data__[e]},Se.prototype.get=function(e){var t=this.__data__;if(ve){var r=t[e];return r===o?void 0:r}return Y.call(t,e)?t[e]:void 0},Se.prototype.has=function(e){var t=this.__data__;return ve?void 0!==t[e]:Y.call(t,e)},Se.prototype.set=function(e,t){return this.__data__[e]=ve&&void 0===t?o:t,this},ke.prototype.clear=function(){this.__data__=[]},ke.prototype.delete=function(e){var t=this.__data__,r=Ee(t,e);return!(r<0||(r==t.length-1?t.pop():ce.call(t,r,1),0))},ke.prototype.get=function(e){var t=this.__data__,r=Ee(t,e);return r<0?void 0:t[r][1]},ke.prototype.has=function(e){return Ee(this.__data__,e)>-1},ke.prototype.set=function(e,t){var r=this.__data__,n=Ee(r,e);return n<0?r.push([e,t]):r[n][1]=t,this},Ae.prototype.clear=function(){this.__data__={hash:new Se,map:new(he||ke),string:new Se}},Ae.prototype.delete=function(e){return De(this,e).delete(e)},Ae.prototype.get=function(e){return De(this,e).get(e)},Ae.prototype.has=function(e){return De(this,e).has(e)},Ae.prototype.set=function(e,t){return De(this,e).set(e,t),this},Te.prototype.clear=function(){this.__data__=new ke},Te.prototype.delete=function(e){return this.__data__.delete(e)},Te.prototype.get=function(e){return this.__data__.get(e)},Te.prototype.has=function(e){return this.__data__.has(e)},Te.prototype.set=function(e,t){var r=this.__data__;if(r instanceof ke){var o=r.__data__;if(!he||o.length<n-1)return o.push([e,t]),this;r=this.__data__=new Ae(o)}return r.set(e,t),this};var Je=se?K(se,Object):function(){return[]},Re=function(e){return ee.call(e)};function Ce(e,t){return!!(t=null==t?i:t)&&("number"==typeof e||E.test(e))&&e>-1&&e%1==0&&e<t}function Ve(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||G)}function He(e){if(null!=e){try{return X.call(e)}catch(e){}try{return e+""}catch(e){}}return""}function Le(e,t){return e===t||e!=e&&t!=t}(ye&&Re(new ye(new ArrayBuffer(1)))!=m||he&&Re(new he)!=l||pe&&"[object Promise]"!=Re(pe.resolve())||ge&&Re(new ge)!=g||de&&"[object WeakMap]"!=Re(new de))&&(Re=function(e){var t=ee.call(e),r=t==h?e.constructor:void 0,n=r?He(r):void 0;if(n)switch(n){case be:return m;case me:return l;case je:return"[object Promise]";case _e:return g;case we:return"[object WeakMap]"}return t});var Ke=Array.isArray;function qe(e){return null!=e&&function(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=i}(e.length)&&!Be(e)}var Ze=fe||function(){return!1};function Be(e){var t=Ue(e)?ee.call(e):"";return t==s||t==f}function Ue(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function Ge(e){return qe(e)?Ne(e):function(e){if(!Ve(e))return le(e);var t=[];for(var r in Object(e))Y.call(e,r)&&"constructor"!=r&&t.push(r);return t}(e)}t.exports=function(e){return We(e,!0,!0)}}),n=1/0,o=9007199254740991,i=1.7976931348623157e308,a=NaN,u="[object Arguments]",c="[object Function]",s="[object GeneratorFunction]",f="[object String]",l="[object Symbol]",y=/^\s+|\s+$/g,h=/^[-+]0x[0-9a-f]+$/i,p=/^0b[01]+$/i,g=/^0o[0-7]+$/i,d=/^(?:0|[1-9]\d*)$/,v=parseInt;function b(e){return e!=e}function m(e,t){return function(e,t){for(var r=-1,n=e?e.length:0,o=Array(n);++r<n;)o[r]=t(e[r],r,e);return o}(t,function(t){return e[t]})}var j,_,w=Object.prototype,O=w.hasOwnProperty,$=w.toString,S=w.propertyIsEnumerable,k=(j=Object.keys,_=Object,function(e){return j(_(e))}),A=Math.max;function T(e,t){var r=E(e)||function(e){return function(e){return P(e)&&W(e)}(e)&&O.call(e,"callee")&&(!S.call(e,"callee")||$.call(e)==u)}(e)?function(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}(e.length,String):[],n=r.length,o=!!n;for(var i in e)!t&&!O.call(e,i)||o&&("length"==i||x(i,n))||r.push(i);return r}function N(e){if(r=(t=e)&&t.constructor,n="function"==typeof r&&r.prototype||w,t!==n)return k(e);var t,r,n,o=[];for(var i in Object(e))O.call(e,i)&&"constructor"!=i&&o.push(i);return o}function x(e,t){return!!(t=null==t?o:t)&&("number"==typeof e||d.test(e))&&e>-1&&e%1==0&&e<t}var E=Array.isArray;function W(e){return null!=e&&function(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=o}(e.length)&&!function(e){var t=I(e)?$.call(e):"";return t==c||t==s}(e)}function I(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function P(e){return!!e&&"object"==typeof e}var M=function(e,t,r,o){var u;e=W(e)?e:(u=e)?m(u,function(e){return W(e)?T(e):N(e)}(u)):[],r=r&&!o?function(e){var t=function(e){if(!e)return 0===e?e:0;if((e=function(e){if("number"==typeof e)return e;if(function(e){return"symbol"==typeof e||P(e)&&$.call(e)==l}(e))return a;if(I(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=I(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=e.replace(y,"");var r=p.test(e);return r||g.test(e)?v(e.slice(2),r?2:8):h.test(e)?a:+e}(e))===n||e===-n){var t=e<0?-1:1;return t*i}return e==e?e:0}(e),r=t%1;return t==t?r?t-r:t:0}(r):0;var c=e.length;return r<0&&(r=A(c+r,0)),function(e){return"string"==typeof e||!E(e)&&P(e)&&$.call(e)==f}(e)?r<=c&&e.indexOf(t,r)>-1:!!c&&function(e,t,r){if(t!=t)return function(e,t,r,n){for(var o=e.length,i=r+(n?1:-1);n?i--:++i<o;)if(t(e[i],i,e))return i;return-1}(e,b,r);for(var n=r-1,o=e.length;++n<o;)if(e[n]===t)return n;return-1}(e,t,r)>-1},D=t(function(t,r){var n,o,i,a,u,c,s,f,l,y,h,p,g,d,v,b,m,j,_,w;t.exports=(n="function"==typeof Promise,o="object"==typeof self?self:e,i="undefined"!=typeof Symbol,a="undefined"!=typeof Map,u="undefined"!=typeof Set,c="undefined"!=typeof WeakMap,s="undefined"!=typeof WeakSet,f="undefined"!=typeof DataView,l=i&&void 0!==Symbol.iterator,y=i&&void 0!==Symbol.toStringTag,h=u&&"function"==typeof Set.prototype.entries,p=a&&"function"==typeof Map.prototype.entries,g=h&&Object.getPrototypeOf((new Set).entries()),d=p&&Object.getPrototypeOf((new Map).entries()),v=l&&"function"==typeof Array.prototype[Symbol.iterator],b=v&&Object.getPrototypeOf([][Symbol.iterator]()),m=l&&"function"==typeof String.prototype[Symbol.iterator],j=m&&Object.getPrototypeOf(""[Symbol.iterator]()),_=8,w=-1,function(e){var t=typeof e;if("object"!==t)return t;if(null===e)return"null";if(e===o)return"global";if(Array.isArray(e)&&(!1===y||!(Symbol.toStringTag in e)))return"Array";if("object"==typeof window&&null!==window){if("object"==typeof window.location&&e===window.location)return"Location";if("object"==typeof window.document&&e===window.document)return"Document";if("object"==typeof window.navigator){if("object"==typeof window.navigator.mimeTypes&&e===window.navigator.mimeTypes)return"MimeTypeArray";if("object"==typeof window.navigator.plugins&&e===window.navigator.plugins)return"PluginArray"}if(("function"==typeof window.HTMLElement||"object"==typeof window.HTMLElement)&&e instanceof window.HTMLElement){if("BLOCKQUOTE"===e.tagName)return"HTMLQuoteElement";if("TD"===e.tagName)return"HTMLTableDataCellElement";if("TH"===e.tagName)return"HTMLTableHeaderCellElement"}}var r=y&&e[Symbol.toStringTag];if("string"==typeof r)return r;var i=Object.getPrototypeOf(e);return i===RegExp.prototype?"RegExp":i===Date.prototype?"Date":n&&i===Promise.prototype?"Promise":u&&i===Set.prototype?"Set":a&&i===Map.prototype?"Map":s&&i===WeakSet.prototype?"WeakSet":c&&i===WeakMap.prototype?"WeakMap":f&&i===DataView.prototype?"DataView":a&&i===d?"Map Iterator":u&&i===g?"Set Iterator":v&&i===b?"Array Iterator":m&&i===j?"String Iterator":null===i?"Object":Object.prototype.toString.call(e).slice(_,w)})});function F(e,t,r){if(t!=t)return function(e,t,r,n){for(var o=e.length,i=r+(n?1:-1);n?i--:++i<o;)if(t(e[i],i,e))return i;return-1}(e,R,r);for(var n=r-1,o=e.length;++n<o;)if(e[n]===t)return n;return-1}function J(e,t,r,n){for(var o=r-1,i=e.length;++o<i;)if(n(e[o],t))return o;return-1}function R(e){return e!=e}var C=Array.prototype.splice;function V(e,t,r,n){var o,i=n?J:F,a=-1,u=t.length,c=e;for(e===t&&(t=function(e,t){var r=-1,n=e.length;t||(t=Array(n));for(;++r<n;)t[r]=e[r];return t}(t)),r&&(c=function(e,t){for(var r=-1,n=e?e.length:0,o=Array(n);++r<n;)o[r]=t(e[r],r,e);return o}(e,(o=r,function(e){return o(e)})));++a<u;)for(var s=0,f=t[a],l=r?r(f):f;(s=i(c,l,s,n))>-1;)c!==e&&C.call(c,s,1),C.call(e,s,1);return e}var H=function(e,t){return e&&e.length&&t&&t.length?V(e,t):e},L="[object Object]";var K=Function.prototype,q=Object.prototype,Z=K.toString,B=q.hasOwnProperty,U=Z.call(Object),G=q.toString,z=function(e,t){return function(r){return e(t(r))}}(Object.getPrototypeOf,Object);var Q=function(e){if(!function(e){return!!e&&"object"==typeof e}(e)||G.call(e)!=L||function(e){var t=!1;if(null!=e&&"function"!=typeof e.toString)try{t=!!(e+"")}catch(e){}return t}(e))return!1;var t=z(e);if(null===t)return!0;var r=B.call(t,"constructor")&&t.constructor;return"function"==typeof r&&r instanceof r&&Z.call(r)==U};const X=Array.isArray;function Y(e){return"string"==typeof e&&e.length>0&&"."===e[0]?e.slice(1):e}function ee(e,t){return function e(t,n,o){const i=r(t);let a,u,c,s,f;if((o=Object.assign({depth:-1,path:""},o)).depth+=1,X(i))for(a=0,u=i.length;a<u;a++){const t=`${o.path}.${a}`;void 0!==i[a]?(o.parent=r(i),o.parentType="array",c=e(n(i[a],void 0,Object.assign({},o,{path:Y(t)})),n,Object.assign({},o,{path:Y(t)})),Number.isNaN(c)&&a<i.length?(i.splice(a,1),a-=1):i[a]=c):i.splice(a,1)}else if(Q(i))for(a=0,u=(s=Object.keys(i)).length;a<u;a++){f=s[a];const t=`${o.path}.${f}`;0===o.depth&&null!=f&&(o.topmostKey=f),o.parent=r(i),o.parentType="object",c=e(n(f,i[f],Object.assign({},o,{path:Y(t)})),n,Object.assign({},o,{path:Y(t)})),Number.isNaN(c)?delete i[f]:i[f]=c}return i}(e,t,{})}var te="__lodash_hash_undefined__",re=9007199254740991,ne="[object Function]",oe="[object GeneratorFunction]",ie=/^\[object .+?Constructor\]$/,ae="object"==typeof e&&e&&e.Object===Object&&e,ue="object"==typeof self&&self&&self.Object===Object&&self,ce=ae||ue||Function("return this")();function se(e,t){return!!(e?e.length:0)&&function(e,t,r){if(t!=t)return function(e,t,r,n){var o=e.length,i=r+(n?1:-1);for(;n?i--:++i<o;)if(t(e[i],i,e))return i;return-1}(e,ye,r);var n=r-1,o=e.length;for(;++n<o;)if(e[n]===t)return n;return-1}(e,t,0)>-1}function fe(e,t,r){for(var n=-1,o=e?e.length:0;++n<o;)if(r(t,e[n]))return!0;return!1}function le(e,t){for(var r=-1,n=e?e.length:0,o=Array(n);++r<n;)o[r]=t(e[r],r,e);return o}function ye(e){return e!=e}function he(e){return function(t){return e(t)}}function pe(e,t){return e.has(t)}var ge,de=Array.prototype,ve=Function.prototype,be=Object.prototype,me=ce["__core-js_shared__"],je=(ge=/[^.]+$/.exec(me&&me.keys&&me.keys.IE_PROTO||""))?"Symbol(src)_1."+ge:"",_e=ve.toString,we=be.hasOwnProperty,Oe=be.toString,$e=RegExp("^"+_e.call(we).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Se=de.splice,ke=Math.max,Ae=Math.min,Te=Je(ce,"Map"),Ne=Je(Object,"create");function xe(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function Ee(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function We(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function Ie(e){var t=-1,r=e?e.length:0;for(this.__data__=new We;++t<r;)this.add(e[t])}function Pe(e,t){for(var r,n,o=e.length;o--;)if((r=e[o][0])===(n=t)||r!=r&&n!=n)return o;return-1}function Me(e){return!(!Ce(e)||(t=e,je&&je in t))&&(Re(e)||function(e){var t=!1;if(null!=e&&"function"!=typeof e.toString)try{t=!!(e+"")}catch(e){}return t}(e)?$e:ie).test(function(e){if(null!=e){try{return _e.call(e)}catch(e){}try{return e+""}catch(e){}}return""}(e));var t}function De(e){return function(e){return function(e){return!!e&&"object"==typeof e}(e)&&function(e){return null!=e&&function(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=re}(e.length)&&!Re(e)}(e)}(e)?e:[]}function Fe(e,t){var r,n,o=e.__data__;return("string"==(n=typeof(r=t))||"number"==n||"symbol"==n||"boolean"==n?"__proto__"!==r:null===r)?o["string"==typeof t?"string":"hash"]:o.map}function Je(e,t){var r=function(e,t){return null==e?void 0:e[t]}(e,t);return Me(r)?r:void 0}function Re(e){var t=Ce(e)?Oe.call(e):"";return t==ne||t==oe}function Ce(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}xe.prototype.clear=function(){this.__data__=Ne?Ne(null):{}},xe.prototype.delete=function(e){return this.has(e)&&delete this.__data__[e]},xe.prototype.get=function(e){var t=this.__data__;if(Ne){var r=t[e];return r===te?void 0:r}return we.call(t,e)?t[e]:void 0},xe.prototype.has=function(e){var t=this.__data__;return Ne?void 0!==t[e]:we.call(t,e)},xe.prototype.set=function(e,t){return this.__data__[e]=Ne&&void 0===t?te:t,this},Ee.prototype.clear=function(){this.__data__=[]},Ee.prototype.delete=function(e){var t=this.__data__,r=Pe(t,e);return!(r<0||(r==t.length-1?t.pop():Se.call(t,r,1),0))},Ee.prototype.get=function(e){var t=this.__data__,r=Pe(t,e);return r<0?void 0:t[r][1]},Ee.prototype.has=function(e){return Pe(this.__data__,e)>-1},Ee.prototype.set=function(e,t){var r=this.__data__,n=Pe(r,e);return n<0?r.push([e,t]):r[n][1]=t,this},We.prototype.clear=function(){this.__data__={hash:new xe,map:new(Te||Ee),string:new xe}},We.prototype.delete=function(e){return Fe(this,e).delete(e)},We.prototype.get=function(e){return Fe(this,e).get(e)},We.prototype.has=function(e){return Fe(this,e).has(e)},We.prototype.set=function(e,t){return Fe(this,e).set(e,t),this},Ie.prototype.add=Ie.prototype.push=function(e){return this.__data__.set(e,te),this},Ie.prototype.has=function(e){return this.__data__.has(e)};var Ve=function(e,t){return t=ke(void 0===t?e.length-1:t,0),function(){for(var r=arguments,n=-1,o=ke(r.length-t,0),i=Array(o);++n<o;)i[n]=r[t+n];n=-1;for(var a=Array(t+1);++n<t;)a[n]=r[n];return a[t]=i,function(e,t,r){switch(r.length){case 0:return e.call(t);case 1:return e.call(t,r[0]);case 2:return e.call(t,r[0],r[1]);case 3:return e.call(t,r[0],r[1],r[2])}return e.apply(t,r)}(e,this,a)}}(function(e){var t=le(e,De);return t.length&&t[0]===e[0]?function(e,t,r){for(var n=r?fe:se,o=e[0].length,i=e.length,a=i,u=Array(i),c=1/0,s=[];a--;){var f=e[a];a&&t&&(f=le(f,he(t))),c=Ae(f.length,c),u[a]=!r&&(t||o>=120&&f.length>=120)?new Ie(a&&f):void 0}f=e[0];var l=-1,y=u[0];e:for(;++l<o&&s.length<c;){var h=f[l],p=t?t(h):h;if(h=r||0!==h?h:0,!(y?pe(y,p):n(s,p,r))){for(a=i;--a;){var g=u[a];if(!(g?pe(g,p):n(e[a],p,r)))continue e}y&&y.push(p),s.push(h)}}return s}(t):[]});function He(e){return"string"==typeof e?e.length>0?[e]:[]:e}var Le=t(function(e){e.exports=function(){var e=Object.prototype.toString;function t(e,t){return null!=e&&Object.prototype.hasOwnProperty.call(e,t)}function r(e){if(!e)return!0;if(o(e)&&0===e.length)return!0;if("string"!=typeof e){for(var r in e)if(t(e,r))return!1;return!0}return!1}function n(t){return e.call(t)}var o=Array.isArray||function(t){return"[object Array]"===e.call(t)};function i(e){var t=parseInt(e);return t.toString()===e?t:e}function a(e){e=e||{};var a=function(e){return Object.keys(a).reduce(function(t,r){return"create"===r?t:("function"==typeof a[r]&&(t[r]=a[r].bind(a,e)),t)},{})};function u(r,n){return e.includeInheritedProps||"number"==typeof n&&Array.isArray(r)||t(r,n)}function c(e,t){if(u(e,t))return e[t]}function s(e,t,r,n){if("number"==typeof t&&(t=[t]),!t||0===t.length)return e;if("string"==typeof t)return s(e,t.split(".").map(i),r,n);var o=t[0],a=c(e,o);return 1===t.length?(void 0!==a&&n||(e[o]=r),a):(void 0===a&&("number"==typeof t[1]?e[o]=[]:e[o]={}),s(e[o],t.slice(1),r,n))}return a.has=function(r,n){if("number"==typeof n?n=[n]:"string"==typeof n&&(n=n.split(".")),!n||0===n.length)return!!r;for(var a=0;a<n.length;a++){var u=i(n[a]);if(!("number"==typeof u&&o(r)&&u<r.length||(e.includeInheritedProps?u in Object(r):t(r,u))))return!1;r=r[u]}return!0},a.ensureExists=function(e,t,r){return s(e,t,r,!0)},a.set=function(e,t,r,n){return s(e,t,r,n)},a.insert=function(e,t,r,n){var i=a.get(e,t);n=~~n,o(i)||(i=[],a.set(e,t,i)),i.splice(n,0,r)},a.empty=function(e,t){var i,c;if(!r(t)&&null!=e&&(i=a.get(e,t))){if("string"==typeof i)return a.set(e,t,"");if(function(e){return"boolean"==typeof e||"[object Boolean]"===n(e)}(i))return a.set(e,t,!1);if("number"==typeof i)return a.set(e,t,0);if(o(i))i.length=0;else{if(!function(e){return"object"==typeof e&&"[object Object]"===n(e)}(i))return a.set(e,t,null);for(c in i)u(i,c)&&delete i[c]}}},a.push=function(e,t){var r=a.get(e,t);o(r)||(r=[],a.set(e,t,r)),r.push.apply(r,Array.prototype.slice.call(arguments,2))},a.coalesce=function(e,t,r){for(var n,o=0,i=t.length;o<i;o++)if(void 0!==(n=a.get(e,t[o])))return n;return r},a.get=function(e,t,r){if("number"==typeof t&&(t=[t]),!t||0===t.length)return e;if(null==e)return r;if("string"==typeof t)return a.get(e,t.split("."),r);var n=i(t[0]),o=c(e,n);return void 0===o?r:1===t.length?o:a.get(e[n],t.slice(1),r)},a.del=function(e,t){if("number"==typeof t&&(t=[t]),null==e)return e;if(r(t))return e;if("string"==typeof t)return a.del(e,t.split("."));var n=i(t[0]);return u(e,n)?1!==t.length?a.del(e[n],t.slice(1)):(o(e)?e.splice(n,1):delete e[n],e):e},a}var u=a();return u.create=a,u.withInheritedProps=a({includeInheritedProps:!0}),u}()}),Ke=function(e){var t=e%100;if(t>=10&&t<=20)return"th";var r=e%10;return 1===r?"st":2===r?"nd":3===r?"rd":"th"};function qe(e){if("number"!=typeof e)throw new TypeError("Expected Number, got "+typeof e+" "+e);return e+Ke(e)}qe.indicator=Ke;var Ze=qe,Be=/[|\\{}()[\]^$+*?.]/g,Ue=function(e){if("string"!=typeof e)throw new TypeError("Expected a string");return e.replace(Be,"\\$&")};const Ge=new Map;function ze(e,t){const r=Object.assign({caseSensitive:!1},t),n=e+JSON.stringify(r);if(Ge.has(n))return Ge.get(n);const o="!"===e[0];o&&(e=e.slice(1)),e=Ue(e).replace(/\\\*/g,".*");const i=new RegExp(`^${e}$`,r.caseSensitive?"":"i");return i.negated=o,Ge.set(n,i),i}var Qe=(e,t,r)=>{if(!Array.isArray(e)||!Array.isArray(t))throw new TypeError(`Expected two arrays, got ${typeof e} ${typeof t}`);if(0===t.length)return e;const n="!"===t[0][0];t=t.map(e=>ze(e,r));const o=[];for(const r of e){let e=n;for(const n of t)n.test(r)&&(e=!n.negated);e&&o.push(r)}return o};function Xe(e,t,r){return function e(t,r,n,o=!0){const i=Object.prototype.hasOwnProperty;function a(e){return null!=e}function u(e){return"Object"===D(e)}function c(e,t){return t=He(t),Array.from(e).filter(e=>!t.some(t=>Qe.isMatch(e,t,{caseSensitive:!0})))}const s=["any","anything","every","everything","all","whatever","whatevs"],f=Array.isArray;if(!a(t))throw new Error("check-types-mini: [THROW_ID_01] First argument is missing!");const l={ignoreKeys:[],ignorePaths:[],acceptArrays:!1,acceptArraysIgnore:[],enforceStrictKeyset:!0,schema:{},msg:"check-types-mini",optsVarName:"opts"};let y;if(y=a(n)&&u(n)?Object.assign({},l,n):Object.assign({},l),a(y.ignoreKeys)&&y.ignoreKeys?y.ignoreKeys=He(y.ignoreKeys):y.ignoreKeys=[],a(y.ignorePaths)&&y.ignorePaths?y.ignorePaths=He(y.ignorePaths):y.ignorePaths=[],a(y.acceptArraysIgnore)&&y.acceptArraysIgnore?y.acceptArraysIgnore=He(y.acceptArraysIgnore):y.acceptArraysIgnore=[],y.msg="string"==typeof y.msg?y.msg.trim():y.msg,":"===y.msg[y.msg.length-1]&&(y.msg=y.msg.slice(0,y.msg.length-1).trim()),y.schema&&(Object.keys(y.schema).forEach(e=>{if(u(y.schema[e])){const t={};ee(y.schema[e],(r,n,o)=>{const i=void 0!==n?n:r;return f(i)||u(i)||(t[`${e}.${o.path}`]=i),i}),delete y.schema[e],y.schema=Object.assign(y.schema,t)}}),Object.keys(y.schema).forEach(e=>{f(y.schema[e])||(y.schema[e]=[y.schema[e]]),y.schema[e]=y.schema[e].map(String).map(e=>e.toLowerCase()).map(e=>e.trim())})),a(r)||(r={}),o&&e(y,l,{enforceStrictKeyset:!1},!1),y.enforceStrictKeyset)if(a(y.schema)&&Object.keys(y.schema).length>0){if(0!==c(H(Object.keys(t),Object.keys(r).concat(Object.keys(y.schema))),y.ignoreKeys).length){const e=H(Object.keys(t),Object.keys(r).concat(Object.keys(y.schema)));throw new TypeError(`${y.msg}: ${y.optsVarName}.enforceStrictKeyset is on and the following key${e.length>1?"s":""} ${e.length>1?"are":"is"} not covered by schema and/or reference objects: ${e.join(", ")}`)}}else{if(!(a(r)&&Object.keys(r).length>0))throw new TypeError(`${y.msg}: Both ${y.optsVarName}.schema and reference objects are missing! We don't have anything to match the keys as you requested via opts.enforceStrictKeyset!`);if(0!==c(H(Object.keys(t),Object.keys(r)),y.ignoreKeys).length){const e=H(Object.keys(t),Object.keys(r));throw new TypeError(`${y.msg}: The input object has key${e.length>1?"s":""} which ${e.length>1?"are":"is"} not covered by the reference object: ${e.join(", ")}`)}if(0!==c(H(Object.keys(r),Object.keys(t)),y.ignoreKeys).length){const e=H(Object.keys(r),Object.keys(t));throw new TypeError(`${y.msg}: The reference object has key${e.length>1?"s":""} which ${e.length>1?"are":"is"} not present in the input object: ${e.join(", ")}`)}}const h=[];ee(t,(e,n,o)=>{let a=n,c=e;if("array"===o.parentType&&(c=void 0,a=e),f(h)&&h.length&&h.some(e=>o.path.startsWith(e)))return a;if(c&&y.ignoreKeys.some(e=>Qe.isMatch(c,e)))return a;if(y.ignorePaths.some(e=>Qe.isMatch(o.path,e)))return a;const l=!(!u(a)&&!f(a)&&f(o.parent));let p=!1;u(y.schema)&&i.call(y.schema,Le.get(o.path))&&(p=!0);let g=!1;if(u(r)&&Le.has(r,Le.get(o.path))&&(g=!0),y.enforceStrictKeyset&&l&&!p&&!g)throw new TypeError(`${y.msg}: ${y.optsVarName}.${o.path} is neither covered by reference object (second input argument), nor ${y.optsVarName}.schema! To stop this error, turn off ${y.optsVarName}.enforceStrictKeyset or provide some type reference (2nd argument or ${y.optsVarName}.schema).\n\nDebug info:\n\nobj = ${JSON.stringify(t,null,4)}\n\nref = ${JSON.stringify(r,null,4)}\n\ninnerObj = ${JSON.stringify(o,null,4)}\n\nopts = ${JSON.stringify(y,null,4)}\n\ncurrent = ${JSON.stringify(a,null,4)}\n\n`);if(p){const e=He(y.schema[o.path]).map(String).map(e=>e.toLowerCase());if(Le.set(y.schema,o.path,e),Ve(e,s).length)h.push(o.path);else if(!0!==a&&!1!==a&&!e.includes(D(a).toLowerCase())||(!0===a||!1===a)&&!e.includes(String(a))&&!e.includes("boolean")){if(!f(a)||!y.acceptArrays)throw new TypeError(`${y.msg}: ${y.optsVarName}.${o.path} was customised to ${"string"!==D(a)?'"':""}${JSON.stringify(a,null,0)}${"string"!==D(a)?'"':""} (type: ${D(a).toLowerCase()}) which is not among the allowed types in schema (which is equal to ${JSON.stringify(e,null,0)})`);for(let t=0,r=a.length;t<r;t++)if(!e.includes(D(a[t]).toLowerCase()))throw new TypeError(`${y.msg}: ${y.optsVarName}.${o.path}.${t}, the ${Ze(t+1)} element (equal to ${JSON.stringify(a[t],null,0)}) is of a type ${D(a[t]).toLowerCase()}, but only the following are allowed by the ${y.optsVarName}.schema: ${e.join(", ")}`)}}else if(g){const t=Le.get(r,o.path);if(y.acceptArrays&&f(a)&&!y.acceptArraysIgnore.includes(e)){if(!a.every(t=>D(t).toLowerCase()===D(r[e]).toLowerCase()))throw new TypeError(`${y.msg}: ${y.optsVarName}.${o.path} was customised to be array, but not all of its elements are ${D(r[e]).toLowerCase()}-type`)}else if(D(a)!==D(t))throw new TypeError(`${y.msg}: ${y.optsVarName}.${o.path} was customised to ${"string"===D(a).toLowerCase()?"":'"'}${JSON.stringify(a,null,0)}${"string"===D(a).toLowerCase()?"":'"'} which is not ${D(t).toLowerCase()} but ${D(a).toLowerCase()}`)}return a})}(e,t,r)}function Ye(e,t){function r(e){return null!=e}if(!r(e))throw new Error(`util-array-object-or-both/validate(): [THROW_ID_01] Please provide a string to work on. Currently it's equal to ${JSON.stringify(e,null,4)}`);if("string"!=typeof e)throw new Error(`util-array-object-or-both/validate(): [THROW_ID_02] Input must be string! Currently it's ${typeof e}, equal to: ${JSON.stringify(e,null,4)}`);if(r(t)&&!Q(t))throw new Error(`util-array-object-or-both/validate(): [THROW_ID_03] Second argument, options object, must be, well, object! Currenlty it's: ${typeof t}, equal to: ${JSON.stringify(t,null,4)}`);const n={msg:"",optsVarName:"given variable"},o=Object.assign({},n,t);if(Xe(o,n,{msg:"util-array-object-or-both/validate(): [THROW_ID_03]",optsVarName:"opts",schema:{msg:["string",null],optsVarName:["string",null]}}),r(o.msg)&&o.msg.length>0&&(o.msg=`${o.msg.trim()} `),"given variable"!==o.optsVarName&&(o.optsVarName=`variable "${o.optsVarName}"`),M(["object","objects","obj","ob","o"],e.toLowerCase().trim()))return"object";if(M(["array","arrays","arr","aray","arr","a"],e.toLowerCase().trim()))return"array";if(M(["any","all","everything","both","either","each","whatever","whatevs","e"],e.toLowerCase().trim()))return"any";throw new TypeError(`${o.msg}The ${o.optsVarName} was customised to an unrecognised value: ${e}. Please check it against the API documentation.`)}Qe.isMatch=((e,t,r)=>{const n=ze(t,r),o=n.test(e);return n.negated?!o:o});var et=function(e,t){if(t){if("object"!=typeof t)throw new TypeError(String(t)+" is not an object. Expected an object that has boolean `includeZero` property.");if("includeZero"in t){if("boolean"!=typeof t.includeZero)throw new TypeError(String(t.includeZero)+" is neither true nor false. `includeZero` option must be a Boolean value.");if(t.includeZero&&0===e)return!0}}return Number.isSafeInteger(e)&&e>=1},tt=1/0,rt="[object Symbol]",nt=/^\s+|\s+$/g,ot="[\\ud800-\\udfff]",it="[\\u0300-\\u036f\\ufe20-\\ufe23\\u20d0-\\u20f0]",at="\\ud83c[\\udffb-\\udfff]",ut="[^\\ud800-\\udfff]",ct="(?:\\ud83c[\\udde6-\\uddff]){2}",st="[\\ud800-\\udbff][\\udc00-\\udfff]",ft="(?:"+it+"|"+at+")"+"?",lt="[\\ufe0e\\ufe0f]?"+ft+("(?:\\u200d(?:"+[ut,ct,st].join("|")+")[\\ufe0e\\ufe0f]?"+ft+")*"),yt="(?:"+[ut+it+"?",it,ct,st,ot].join("|")+")",ht=RegExp(at+"(?="+at+")|"+yt+lt,"g"),pt=RegExp("[\\u200d\\ud800-\\udfff\\u0300-\\u036f\\ufe20-\\ufe23\\u20d0-\\u20f0\\ufe0e\\ufe0f]"),gt="object"==typeof e&&e&&e.Object===Object&&e,dt="object"==typeof self&&self&&self.Object===Object&&self,vt=gt||dt||Function("return this")();function bt(e,t,r){if(t!=t)return function(e,t,r,n){for(var o=e.length,i=r+(n?1:-1);n?i--:++i<o;)if(t(e[i],i,e))return i;return-1}(e,mt,r);for(var n=r-1,o=e.length;++n<o;)if(e[n]===t)return n;return-1}function mt(e){return e!=e}function jt(e){return function(e){return pt.test(e)}(e)?function(e){return e.match(ht)||[]}(e):function(e){return e.split("")}(e)}var _t=Object.prototype.toString,wt=vt.Symbol,Ot=wt?wt.prototype:void 0,$t=Ot?Ot.toString:void 0;function St(e){if("string"==typeof e)return e;if(function(e){return"symbol"==typeof e||function(e){return!!e&&"object"==typeof e}(e)&&_t.call(e)==rt}(e))return $t?$t.call(e):"";var t=e+"";return"0"==t&&1/e==-tt?"-0":t}function kt(e,t,r){var n=e.length;return r=void 0===r?n:r,!t&&r>=n?e:function(e,t,r){var n=-1,o=e.length;t<0&&(t=-t>o?0:o+t),(r=r>o?o:r)<0&&(r+=o),o=t>r?0:r-t>>>0,t>>>=0;for(var i=Array(o);++n<o;)i[n]=e[n+t];return i}(e,t,r)}var At=function(e,t,r){var n;if((e=null==(n=e)?"":St(n))&&(r||void 0===t))return e.replace(nt,"");if(!e||!(t=St(t)))return e;var o=jt(e),i=jt(t);return kt(o,function(e,t){for(var r=-1,n=e.length;++r<n&&bt(t,e[r],0)>-1;);return r}(o,i),function(e,t){for(var r=e.length;r--&&bt(t,e[r],0)>-1;);return r}(o,i)+1).join("")};function Tt(e){function t(e){return"string"==typeof e}const r=Array.isArray;let n=!0;return!!(r(e)||Q(e)||t(e))&&(t(e)?0===At(e).length:(e=ee(e,(e,r)=>{const o=void 0!==r?r:e;return t(o)&&""!==At(o)&&(n=!1),o}),n))}const Nt=Array.isArray;function xt(e){return null!=e}function Et(e){return"Object"===D(e)}function Wt(e){return"string"===D(e)}function It(e){return Et(e)||Wt(e)||function(e){return"number"===D(e)}(e)||function(e){return"boolean"===D(e)}(e)||Nt(e)||function(e){return null===e}(e)}const Pt=Array.isArray;function Mt(e,t,n){if(void 0===e)throw new TypeError("ast-compare/compare(): [THROW_ID_01] first argument is missing!");if(void 0===t)throw new TypeError("ast-compare/compare(): [THROW_ID_02] second argument is missing!");if(xt(e)&&!It(e))throw new TypeError(`ast-compare/compare(): [THROW_ID_03] first input argument is of a wrong type, ${D(e)}, equal to: ${JSON.stringify(e,null,4)}`);if(xt(t)&&!It(t))throw new TypeError(`ast-compare/compare(): [THROW_ID_04] second input argument is of a wrong type, ${D(t)}, equal to: ${JSON.stringify(t,null,4)}`);if(xt(n)&&!Et(n))throw new TypeError(`ast-compare/compare(): [THROW_ID_05] third argument, options object, must, well, be an object! Currently it's: ${D(n)} and equal to: ${JSON.stringify(n,null,4)}`);const o=r(t),i=r(e);let a,u,c,s=0;const f={hungryForWhitespace:!1,matchStrictly:!1,verboseWhenMismatches:!1,useWildcards:!1},l=Object.assign({},f,n);if(Xe(l,f,{msg:"ast-compare/compare(): [THROW_ID_06*]"}),l.hungryForWhitespace&&l.matchStrictly&&Et(e)&&Tt(e)&&Et(t)&&0===Object.keys(t).length)return!0;if((!l.hungryForWhitespace||l.hungryForWhitespace&&!Tt(e)&&Tt(t))&&Et(e)&&0!==Object.keys(e).length&&Et(t)&&0===Object.keys(t).length||D(e)!==D(t)&&(!l.hungryForWhitespace||l.hungryForWhitespace&&!Tt(e)))return!1;if(Wt(i)&&Wt(o))return!!(l.hungryForWhitespace&&Tt(i)&&Tt(o))||(l.verboseWhenMismatches?i===o||`Given string ${o} is not matched! We have ${i} on the other end.`:l.useWildcards?Qe.isMatch(i,o,{caseSensitive:!0}):i===o);if(Pt(i)&&Pt(o)){if(l.hungryForWhitespace&&Tt(o)&&(!l.matchStrictly||l.matchStrictly&&i.length===o.length))return!0;if(!l.hungryForWhitespace&&o.length>i.length||l.matchStrictly&&o.length!==i.length)return!!l.verboseWhenMismatches&&`The length of a given array, ${JSON.stringify(o,null,4)} is ${o.length} but the length of an array on the other end, ${JSON.stringify(i,null,4)} is ${i.length}`;if(0===o.length)return 0===i.length||!!l.verboseWhenMismatches&&`The given array has no elements, but the array on the other end, ${JSON.stringify(i,null,4)} does have some`;for(let e=0,t=o.length;e<t;e++){c=!1;for(let t=s,r=i.length;t<r;t++)if(s+=1,!0===Mt(i[t],o[e],l)){c=!0;break}if(!c)return!!l.verboseWhenMismatches&&`The given array ${JSON.stringify(o,null,4)} is not a subset of an array on the other end, ${JSON.stringify(i,null,4)}`}}else{if(!Et(i)||!Et(o))return!!(l.hungryForWhitespace&&Tt(i)&&Tt(o)&&(!l.matchStrictly||l.matchStrictly&&(y=o,Et(y)?0===Object.keys(y).length:(Nt(y)||Wt(y))&&0===y.length)))||i===o;if(a=Object.keys(o),u=Object.keys(i),l.matchStrictly&&a.length!==u.length){if(!l.verboseWhenMismatches)return!1;const e=H(r(a),r(u)),t=e.length>0?`First object has unique keys: ${JSON.stringify(e,null,4)}.`:"",n=H(r(u),r(a));return`When matching strictly, we found that both objects have different amount of keys. ${t} ${n.length>0?`Second object has unique keys:\n ${JSON.stringify(n,null,4)}.`:""}`}for(let e=0,t=a.length;e<t;e++){if(!xt(i[a[e]]))return!l.useWildcards||l.useWildcards&&!a[e].includes("*")?!!l.verboseWhenMismatches&&`The given object has key ${a[e]} which the other-one does not have.`:!!Object.keys(i).some(t=>Qe.isMatch(t,a[e],{caseSensitive:!0}))||!!l.verboseWhenMismatches&&`The given object has key ${a[e]} which the other-one does not have.`;if(void 0!==i[a[e]]&&!It(i[a[e]]))throw new TypeError(`ast-compare/compare(): [THROW_ID_07] The input ${JSON.stringify(i,null,4)} contains a value of a wrong type, ${D(i[a[e]])} at index ${e}, equal to: ${JSON.stringify(i[a[e]],null,4)}`);if(!It(o[a[e]]))throw new TypeError(`ast-compare/compare(): [THROW_ID_08] The input ${JSON.stringify(o,null,4)} contains a value of a wrong type, ${D(o[a[e]])} at index ${e}, equal to: ${JSON.stringify(o[a[e]],null,4)}`);if(xt(i[a[e]])&&D(i[a[e]])!==D(o[a[e]])){if(!(Tt(i[a[e]])&&Tt(o[a[e]])&&l.hungryForWhitespace))return!!l.verboseWhenMismatches&&`The given key ${a[e]} is of a different type on both objects. On the first-one, it's ${D(o[a[e]])}, on the second-one, it's ${D(i[a[e]])}`}else if(!0!==Mt(i[a[e]],o[a[e]],l))return!!l.verboseWhenMismatches&&`The given piece ${JSON.stringify(o[a[e]],null,4)} and ${JSON.stringify(i[a[e]],null,4)} don't match.`}}var y;return!0}function Dt(e){return null!=e}function Ft(e){return void 0!==e}function Jt(e,t){return D(e)===D(t)&&Mt(e,t,{matchStrictly:!0,useWildcards:!0})}function Rt(e,t){if(!Dt(e))throw new Error("ast-monkey/main.js/monkey(): Please provide an input");let n=r(e);(t=Object.assign({key:null,val:void 0},t)).mode;const o={count:0,gatherPath:[],finding:null},i=[];let a=!1,u=!1;return Dt(t.key)&&!Ft(t.val)&&(a=!0),!Dt(t.key)&&Ft(t.val)&&(u=!0),t.mode,t.mode,"arrayFirstOnly"===t.mode&&Array.isArray(n)&&n.length>0&&(n=[n[0]]),n=ee(n,(e,n,c)=>{let s;if(o.count+=1,t.mode,t.mode,t.mode,o.gatherPath.length=c.depth,o.gatherPath.push(o.count),t.mode,"get"===t.mode)o.count===t.index&&(Ft(n)?(o.finding={},o.finding[e]=n):o.finding=e);else if("find"===t.mode||"del"===t.mode){if(!("any"===t.only||"array"===t.only&&void 0===n||"object"===t.only&&void 0!==n)||!(a&&Jt(e,t.key)||u&&Jt(n,t.val)||!a&&!u&&Jt(e,t.key)&&Jt(n,t.val)))return void 0!==n?n:e;if("find"!==t.mode)return NaN;(s={}).index=o.count,s.key=e,s.val=n,s.path=r(o.gatherPath),i.push(s)}return t.mode,"set"===t.mode&&o.count===t.index?t.val:"drop"===t.mode&&o.count===t.index?NaN:"arrayFirstOnly"===t.mode?Ft(n)&&Array.isArray(n)?[n[0]]:Dt(e)&&Array.isArray(e)?[e[0]]:void 0!==n?n:e:void 0!==n?n:e}),"get"===t.mode?o.finding:"find"===t.mode?i.length>0?i:null:n}function Ct(e,t){if(!Ft(t.key)&&!Ft(t.val))throw new Error("ast-monkey/main.js/find(): Please provide opts.key or opts.val");return Xe(t,null,{schema:{key:["null","string"],val:"any",only:["undefined","null","string"]}}),"string"==typeof t.only&&t.only.length>0?t.only=Ye(t.only,{msg:"ast-monkey/find():",optsVarName:"opts.only"}):t.only="any",Rt(e,Object.assign({},t,{mode:"find"}))}function Vt(e,t){if(!Dt(t.index))throw new Error("ast-monkey/main.js/get(): Please provide opts.index");if("string"==typeof t.index){if(!et(parseFloat(t.index,10),{includeZero:!0}))throw new Error(`ast-monkey/main.js/get(): opts.index must be a natural number. It was given as: ${t.index}`);t.index=parseInt(t.index,10)}if(Xe(t,null,{schema:{index:"number"}}),!et(t.index,{includeZero:!0}))throw new Error(`ast-monkey/main.js/get(): opts.index must be a natural number. It was given as: ${t.index}`);return Rt(e,Object.assign({},t,{mode:"get"}))}function Ht(e,t){if(!Dt(t.index))throw new Error("ast-monkey/main.js/drop(): Please provide opts.index");if("string"==typeof t.index){if(!et(parseFloat(t.index,10),{includeZero:!0}))throw new Error(`ast-monkey/main.js/drop(): opts.index must be a natural number. It was given as: ${t.index}`);t.index=parseInt(t.index,10)}if(!et(t.index,{includeZero:!0}))throw new Error(`ast-monkey/main.js/get(): opts.index must be a natural number. It was given as: ${t.index}`);return Xe(t,null,{schema:{index:"number"}}),Rt(e,Object.assign({},t,{mode:"drop"}))}function Lt(e,t){if(!Dt(t.key)&&!Ft(t.val))throw new Error("ast-monkey/main.js/del(): Please provide opts.key or opts.val");return Xe(t,null,{schema:{key:[null,"string"],val:"any",only:["undefined","null","string"]}}),"string"==typeof t.only&&t.only.length>0?t.only=Ye(t.only,{msg:"ast-monkey/del():",optsVarName:"opts.only"}):t.only="any",Rt(e,Object.assign({},t,{mode:"del"}))}function Kt(e){let t,r,n=!0;if(Array.isArray(e)){if(0===e.length)return!0;for(t=0,r=e.length;t<r;t++){if(null===(n=Kt(e[t])))return null;if(!n)return!1}}else if(Q(e)){if(0===Object.keys(e).length)return!0;for(t=0,r=Object.keys(e).length;t<r;t++){if(null===(n=Kt(e[Object.keys(e)[t]])))return null;if(!n)return!1}}else{if("string"!=typeof e)return null;if(0!==e.length)return!1}return n}return function(e,t){function n(e){return null!=e}if(!n(e))throw new Error("object-delete-key/deleteKey(): [THROW_ID_01] Please provide the first argument, something to work upon.");if(arguments.length>2)throw new Error("object-delete-key/deleteKey(): [THROW_ID_02] Third argument detected! Computer does not like this...");var o={key:null,val:void 0,cleanup:!0,only:"any"},i=Object.assign({},o,t);if(Xe(i,o,{msg:"object-delete-key/deleteKey(): [THROW_ID_00*]",ignorePaths:"val.*",schema:{key:["null","string"],val:"whatever"}}),i.only=Ye(i.only,{msg:"object-delete-key/deleteKey(): [THROW_ID_03]",optsVarName:"opts.only"}),!n(i.key)&&!n(i.val))throw new Error("object-delete-key/deleteKey(): [THROW_ID_04] Please provide at least a key or a value.");var a=r(e);if(i.cleanup){for(var u,c,s=Ct(a,{key:i.key,val:i.val,only:i.only});s;){c=s[0].index;for(var f=1,l=s[0].path.length;f<l;f++)Kt(Lt(Vt(a,{index:u=s[0].path[l-1-f]}),{key:i.key,val:i.val,only:i.only}))&&(c=u);s=Ct(a=Ht(a,{index:c}),{key:i.key,val:i.val,only:i.only})}return a}return Lt(a,{key:i.key,val:i.val,only:i.only})}});
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e=e||self).objectDeleteKey=t()}(this,function(){"use strict";var e="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function t(e,t){return e(t={exports:{}},t.exports),t.exports}var r=t(function(t,r){var n=200,o="__lodash_hash_undefined__",i=9007199254740991,a="[object Arguments]",u="[object Boolean]",c="[object Date]",s="[object Function]",f="[object GeneratorFunction]",l="[object Map]",y="[object Number]",h="[object Object]",p="[object RegExp]",g="[object Set]",d="[object String]",b="[object Symbol]",v="[object ArrayBuffer]",m="[object DataView]",j="[object Float32Array]",_="[object Float64Array]",w="[object Int8Array]",O="[object Int16Array]",$="[object Int32Array]",S="[object Uint8Array]",k="[object Uint8ClampedArray]",A="[object Uint16Array]",T="[object Uint32Array]",N=/\w*$/,x=/^\[object .+?Constructor\]$/,E=/^(?:0|[1-9]\d*)$/,W={};W[a]=W["[object Array]"]=W[v]=W[m]=W[u]=W[c]=W[j]=W[_]=W[w]=W[O]=W[$]=W[l]=W[y]=W[h]=W[p]=W[g]=W[d]=W[b]=W[S]=W[k]=W[A]=W[T]=!0,W["[object Error]"]=W[s]=W["[object WeakMap]"]=!1;var I="object"==typeof e&&e&&e.Object===Object&&e,P="object"==typeof self&&self&&self.Object===Object&&self,M=I||P||Function("return this")(),F=r&&!r.nodeType&&r,D=F&&t&&!t.nodeType&&t,J=D&&D.exports===F;function R(e,t){return e.set(t[0],t[1]),e}function C(e,t){return e.add(t),e}function V(e,t,r,n){var o=-1,i=e?e.length:0;for(n&&i&&(r=e[++o]);++o<i;)r=t(r,e[o],o,e);return r}function H(e){var t=!1;if(null!=e&&"function"!=typeof e.toString)try{t=!!(e+"")}catch(e){}return t}function L(e){var t=-1,r=Array(e.size);return e.forEach(function(e,n){r[++t]=[n,e]}),r}function K(e,t){return function(r){return e(t(r))}}function q(e){var t=-1,r=Array(e.size);return e.forEach(function(e){r[++t]=e}),r}var Z,B=Array.prototype,U=Function.prototype,G=Object.prototype,z=M["__core-js_shared__"],Q=(Z=/[^.]+$/.exec(z&&z.keys&&z.keys.IE_PROTO||""))?"Symbol(src)_1."+Z:"",X=U.toString,Y=G.hasOwnProperty,ee=G.toString,te=RegExp("^"+X.call(Y).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),re=J?M.Buffer:void 0,ne=M.Symbol,oe=M.Uint8Array,ie=K(Object.getPrototypeOf,Object),ae=Object.create,ue=G.propertyIsEnumerable,ce=B.splice,se=Object.getOwnPropertySymbols,fe=re?re.isBuffer:void 0,le=K(Object.keys,Object),ye=De(M,"DataView"),he=De(M,"Map"),pe=De(M,"Promise"),ge=De(M,"Set"),de=De(M,"WeakMap"),be=De(Object,"create"),ve=He(ye),me=He(he),je=He(pe),_e=He(ge),we=He(de),Oe=ne?ne.prototype:void 0,$e=Oe?Oe.valueOf:void 0;function Se(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function ke(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function Ae(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function Te(e){this.__data__=new ke(e)}function Ne(e,t){var r=Ke(e)||function(e){return function(e){return function(e){return!!e&&"object"==typeof e}(e)&&qe(e)}(e)&&Y.call(e,"callee")&&(!ue.call(e,"callee")||ee.call(e)==a)}(e)?function(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}(e.length,String):[],n=r.length,o=!!n;for(var i in e)!t&&!Y.call(e,i)||o&&("length"==i||Ce(i,n))||r.push(i);return r}function xe(e,t,r){var n=e[t];Y.call(e,t)&&Le(n,r)&&(void 0!==r||t in e)||(e[t]=r)}function Ee(e,t){for(var r=e.length;r--;)if(Le(e[r][0],t))return r;return-1}function We(e,t,r,n,o,i,x){var E;if(n&&(E=i?n(e,o,i,x):n(e)),void 0!==E)return E;if(!Ue(e))return e;var I=Ke(e);if(I){if(E=function(e){var t=e.length,r=e.constructor(t);t&&"string"==typeof e[0]&&Y.call(e,"index")&&(r.index=e.index,r.input=e.input);return r}(e),!t)return function(e,t){var r=-1,n=e.length;t||(t=Array(n));for(;++r<n;)t[r]=e[r];return t}(e,E)}else{var P=Re(e),M=P==s||P==f;if(Ze(e))return function(e,t){if(t)return e.slice();var r=new e.constructor(e.length);return e.copy(r),r}(e,t);if(P==h||P==a||M&&!i){if(H(e))return i?e:{};if(E=function(e){return"function"!=typeof e.constructor||Ve(e)?{}:(t=ie(e),Ue(t)?ae(t):{});var t}(M?{}:e),!t)return function(e,t){return Me(e,Je(e),t)}(e,function(e,t){return e&&Me(t,Ge(t),e)}(E,e))}else{if(!W[P])return i?e:{};E=function(e,t,r,n){var o=e.constructor;switch(t){case v:return Pe(e);case u:case c:return new o(+e);case m:return function(e,t){var r=t?Pe(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.byteLength)}(e,n);case j:case _:case w:case O:case $:case S:case k:case A:case T:return function(e,t){var r=t?Pe(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.length)}(e,n);case l:return function(e,t,r){return V(t?r(L(e),!0):L(e),R,new e.constructor)}(e,n,r);case y:case d:return new o(e);case p:return(s=new(a=e).constructor(a.source,N.exec(a))).lastIndex=a.lastIndex,s;case g:return function(e,t,r){return V(t?r(q(e),!0):q(e),C,new e.constructor)}(e,n,r);case b:return i=e,$e?Object($e.call(i)):{}}var i;var a,s}(e,P,We,t)}}x||(x=new Te);var F=x.get(e);if(F)return F;if(x.set(e,E),!I)var D=r?function(e){return function(e,t,r){var n=t(e);return Ke(e)?n:function(e,t){for(var r=-1,n=t.length,o=e.length;++r<n;)e[o+r]=t[r];return e}(n,r(e))}(e,Ge,Je)}(e):Ge(e);return function(e,t){for(var r=-1,n=e?e.length:0;++r<n&&!1!==t(e[r],r,e););}(D||e,function(o,i){D&&(o=e[i=o]),xe(E,i,We(o,t,r,n,i,e,x))}),E}function Ie(e){return!(!Ue(e)||(t=e,Q&&Q in t))&&(Be(e)||H(e)?te:x).test(He(e));var t}function Pe(e){var t=new e.constructor(e.byteLength);return new oe(t).set(new oe(e)),t}function Me(e,t,r,n){r||(r={});for(var o=-1,i=t.length;++o<i;){var a=t[o],u=n?n(r[a],e[a],a,r,e):void 0;xe(r,a,void 0===u?e[a]:u)}return r}function Fe(e,t){var r,n,o=e.__data__;return("string"==(n=typeof(r=t))||"number"==n||"symbol"==n||"boolean"==n?"__proto__"!==r:null===r)?o["string"==typeof t?"string":"hash"]:o.map}function De(e,t){var r=function(e,t){return null==e?void 0:e[t]}(e,t);return Ie(r)?r:void 0}Se.prototype.clear=function(){this.__data__=be?be(null):{}},Se.prototype.delete=function(e){return this.has(e)&&delete this.__data__[e]},Se.prototype.get=function(e){var t=this.__data__;if(be){var r=t[e];return r===o?void 0:r}return Y.call(t,e)?t[e]:void 0},Se.prototype.has=function(e){var t=this.__data__;return be?void 0!==t[e]:Y.call(t,e)},Se.prototype.set=function(e,t){return this.__data__[e]=be&&void 0===t?o:t,this},ke.prototype.clear=function(){this.__data__=[]},ke.prototype.delete=function(e){var t=this.__data__,r=Ee(t,e);return!(r<0||(r==t.length-1?t.pop():ce.call(t,r,1),0))},ke.prototype.get=function(e){var t=this.__data__,r=Ee(t,e);return r<0?void 0:t[r][1]},ke.prototype.has=function(e){return Ee(this.__data__,e)>-1},ke.prototype.set=function(e,t){var r=this.__data__,n=Ee(r,e);return n<0?r.push([e,t]):r[n][1]=t,this},Ae.prototype.clear=function(){this.__data__={hash:new Se,map:new(he||ke),string:new Se}},Ae.prototype.delete=function(e){return Fe(this,e).delete(e)},Ae.prototype.get=function(e){return Fe(this,e).get(e)},Ae.prototype.has=function(e){return Fe(this,e).has(e)},Ae.prototype.set=function(e,t){return Fe(this,e).set(e,t),this},Te.prototype.clear=function(){this.__data__=new ke},Te.prototype.delete=function(e){return this.__data__.delete(e)},Te.prototype.get=function(e){return this.__data__.get(e)},Te.prototype.has=function(e){return this.__data__.has(e)},Te.prototype.set=function(e,t){var r=this.__data__;if(r instanceof ke){var o=r.__data__;if(!he||o.length<n-1)return o.push([e,t]),this;r=this.__data__=new Ae(o)}return r.set(e,t),this};var Je=se?K(se,Object):function(){return[]},Re=function(e){return ee.call(e)};function Ce(e,t){return!!(t=null==t?i:t)&&("number"==typeof e||E.test(e))&&e>-1&&e%1==0&&e<t}function Ve(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||G)}function He(e){if(null!=e){try{return X.call(e)}catch(e){}try{return e+""}catch(e){}}return""}function Le(e,t){return e===t||e!=e&&t!=t}(ye&&Re(new ye(new ArrayBuffer(1)))!=m||he&&Re(new he)!=l||pe&&"[object Promise]"!=Re(pe.resolve())||ge&&Re(new ge)!=g||de&&"[object WeakMap]"!=Re(new de))&&(Re=function(e){var t=ee.call(e),r=t==h?e.constructor:void 0,n=r?He(r):void 0;if(n)switch(n){case ve:return m;case me:return l;case je:return"[object Promise]";case _e:return g;case we:return"[object WeakMap]"}return t});var Ke=Array.isArray;function qe(e){return null!=e&&function(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=i}(e.length)&&!Be(e)}var Ze=fe||function(){return!1};function Be(e){var t=Ue(e)?ee.call(e):"";return t==s||t==f}function Ue(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function Ge(e){return qe(e)?Ne(e):function(e){if(!Ve(e))return le(e);var t=[];for(var r in Object(e))Y.call(e,r)&&"constructor"!=r&&t.push(r);return t}(e)}t.exports=function(e){return We(e,!0,!0)}}),n=1/0,o=9007199254740991,i=1.7976931348623157e308,a=NaN,u="[object Arguments]",c="[object Function]",s="[object GeneratorFunction]",f="[object String]",l="[object Symbol]",y=/^\s+|\s+$/g,h=/^[-+]0x[0-9a-f]+$/i,p=/^0b[01]+$/i,g=/^0o[0-7]+$/i,d=/^(?:0|[1-9]\d*)$/,b=parseInt;function v(e){return e!=e}function m(e,t){return function(e,t){for(var r=-1,n=e?e.length:0,o=Array(n);++r<n;)o[r]=t(e[r],r,e);return o}(t,function(t){return e[t]})}var j,_,w=Object.prototype,O=w.hasOwnProperty,$=w.toString,S=w.propertyIsEnumerable,k=(j=Object.keys,_=Object,function(e){return j(_(e))}),A=Math.max;function T(e,t){var r=E(e)||function(e){return function(e){return P(e)&&W(e)}(e)&&O.call(e,"callee")&&(!S.call(e,"callee")||$.call(e)==u)}(e)?function(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}(e.length,String):[],n=r.length,o=!!n;for(var i in e)!t&&!O.call(e,i)||o&&("length"==i||x(i,n))||r.push(i);return r}function N(e){if(r=(t=e)&&t.constructor,n="function"==typeof r&&r.prototype||w,t!==n)return k(e);var t,r,n,o=[];for(var i in Object(e))O.call(e,i)&&"constructor"!=i&&o.push(i);return o}function x(e,t){return!!(t=null==t?o:t)&&("number"==typeof e||d.test(e))&&e>-1&&e%1==0&&e<t}var E=Array.isArray;function W(e){return null!=e&&function(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=o}(e.length)&&!function(e){var t=I(e)?$.call(e):"";return t==c||t==s}(e)}function I(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function P(e){return!!e&&"object"==typeof e}var M=function(e,t,r,o){var u;e=W(e)?e:(u=e)?m(u,function(e){return W(e)?T(e):N(e)}(u)):[],r=r&&!o?function(e){var t=function(e){if(!e)return 0===e?e:0;if((e=function(e){if("number"==typeof e)return e;if(function(e){return"symbol"==typeof e||P(e)&&$.call(e)==l}(e))return a;if(I(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=I(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=e.replace(y,"");var r=p.test(e);return r||g.test(e)?b(e.slice(2),r?2:8):h.test(e)?a:+e}(e))===n||e===-n){var t=e<0?-1:1;return t*i}return e==e?e:0}(e),r=t%1;return t==t?r?t-r:t:0}(r):0;var c=e.length;return r<0&&(r=A(c+r,0)),function(e){return"string"==typeof e||!E(e)&&P(e)&&$.call(e)==f}(e)?r<=c&&e.indexOf(t,r)>-1:!!c&&function(e,t,r){if(t!=t)return function(e,t,r,n){for(var o=e.length,i=r+(n?1:-1);n?i--:++i<o;)if(t(e[i],i,e))return i;return-1}(e,v,r);for(var n=r-1,o=e.length;++n<o;)if(e[n]===t)return n;return-1}(e,t,r)>-1},F=t(function(t,r){var n,o,i,a,u,c,s,f,l,y,h,p,g,d,b,v,m,j,_,w;t.exports=(n="function"==typeof Promise,o="object"==typeof self?self:e,i="undefined"!=typeof Symbol,a="undefined"!=typeof Map,u="undefined"!=typeof Set,c="undefined"!=typeof WeakMap,s="undefined"!=typeof WeakSet,f="undefined"!=typeof DataView,l=i&&void 0!==Symbol.iterator,y=i&&void 0!==Symbol.toStringTag,h=u&&"function"==typeof Set.prototype.entries,p=a&&"function"==typeof Map.prototype.entries,g=h&&Object.getPrototypeOf((new Set).entries()),d=p&&Object.getPrototypeOf((new Map).entries()),b=l&&"function"==typeof Array.prototype[Symbol.iterator],v=b&&Object.getPrototypeOf([][Symbol.iterator]()),m=l&&"function"==typeof String.prototype[Symbol.iterator],j=m&&Object.getPrototypeOf(""[Symbol.iterator]()),_=8,w=-1,function(e){var t=typeof e;if("object"!==t)return t;if(null===e)return"null";if(e===o)return"global";if(Array.isArray(e)&&(!1===y||!(Symbol.toStringTag in e)))return"Array";if("object"==typeof window&&null!==window){if("object"==typeof window.location&&e===window.location)return"Location";if("object"==typeof window.document&&e===window.document)return"Document";if("object"==typeof window.navigator){if("object"==typeof window.navigator.mimeTypes&&e===window.navigator.mimeTypes)return"MimeTypeArray";if("object"==typeof window.navigator.plugins&&e===window.navigator.plugins)return"PluginArray"}if(("function"==typeof window.HTMLElement||"object"==typeof window.HTMLElement)&&e instanceof window.HTMLElement){if("BLOCKQUOTE"===e.tagName)return"HTMLQuoteElement";if("TD"===e.tagName)return"HTMLTableDataCellElement";if("TH"===e.tagName)return"HTMLTableHeaderCellElement"}}var r=y&&e[Symbol.toStringTag];if("string"==typeof r)return r;var i=Object.getPrototypeOf(e);return i===RegExp.prototype?"RegExp":i===Date.prototype?"Date":n&&i===Promise.prototype?"Promise":u&&i===Set.prototype?"Set":a&&i===Map.prototype?"Map":s&&i===WeakSet.prototype?"WeakSet":c&&i===WeakMap.prototype?"WeakMap":f&&i===DataView.prototype?"DataView":a&&i===d?"Map Iterator":u&&i===g?"Set Iterator":b&&i===v?"Array Iterator":m&&i===j?"String Iterator":null===i?"Object":Object.prototype.toString.call(e).slice(_,w)})});function D(e,t,r){if(t!=t)return function(e,t,r,n){for(var o=e.length,i=r+(n?1:-1);n?i--:++i<o;)if(t(e[i],i,e))return i;return-1}(e,R,r);for(var n=r-1,o=e.length;++n<o;)if(e[n]===t)return n;return-1}function J(e,t,r,n){for(var o=r-1,i=e.length;++o<i;)if(n(e[o],t))return o;return-1}function R(e){return e!=e}var C=Array.prototype.splice;function V(e,t,r,n){var o=n?J:D,i=-1,a=t.length,u=e;for(e===t&&(t=function(e,t){var r=-1,n=e.length;t||(t=Array(n));for(;++r<n;)t[r]=e[r];return t}(t)),r&&(u=function(e,t){for(var r=-1,n=e?e.length:0,o=Array(n);++r<n;)o[r]=t(e[r],r,e);return o}(e,function(e){return function(t){return e(t)}}(r)));++i<a;)for(var c=0,s=t[i],f=r?r(s):s;(c=o(u,f,c,n))>-1;)u!==e&&C.call(u,c,1),C.call(e,c,1);return e}var H=function(e,t){return e&&e.length&&t&&t.length?V(e,t):e},L="[object Object]";var K=Function.prototype,q=Object.prototype,Z=K.toString,B=q.hasOwnProperty,U=Z.call(Object),G=q.toString,z=function(e,t){return function(r){return e(t(r))}}(Object.getPrototypeOf,Object);var Q=function(e){if(!function(e){return!!e&&"object"==typeof e}(e)||G.call(e)!=L||function(e){var t=!1;if(null!=e&&"function"!=typeof e.toString)try{t=!!(e+"")}catch(e){}return t}(e))return!1;var t=z(e);if(null===t)return!0;var r=B.call(t,"constructor")&&t.constructor;return"function"==typeof r&&r instanceof r&&Z.call(r)==U};const X=Array.isArray;function Y(e){return"string"==typeof e&&e.length>0&&"."===e[0]?e.slice(1):e}function ee(e,t){return function e(t,n,o){const i=r(t);let a,u,c,s,f;if((o=Object.assign({depth:-1,path:""},o)).depth+=1,X(i))for(a=0,u=i.length;a<u;a++){const t=`${o.path}.${a}`;void 0!==i[a]?(o.parent=r(i),o.parentType="array",c=e(n(i[a],void 0,Object.assign({},o,{path:Y(t)})),n,Object.assign({},o,{path:Y(t)})),Number.isNaN(c)&&a<i.length?(i.splice(a,1),a-=1):i[a]=c):i.splice(a,1)}else if(Q(i))for(a=0,u=(s=Object.keys(i)).length;a<u;a++){f=s[a];const t=`${o.path}.${f}`;0===o.depth&&null!=f&&(o.topmostKey=f),o.parent=r(i),o.parentType="object",c=e(n(f,i[f],Object.assign({},o,{path:Y(t)})),n,Object.assign({},o,{path:Y(t)})),Number.isNaN(c)?delete i[f]:i[f]=c}return i}(e,t,{})}var te="__lodash_hash_undefined__",re=9007199254740991,ne="[object Function]",oe="[object GeneratorFunction]",ie=/^\[object .+?Constructor\]$/,ae="object"==typeof e&&e&&e.Object===Object&&e,ue="object"==typeof self&&self&&self.Object===Object&&self,ce=ae||ue||Function("return this")();function se(e,t){return!!(e?e.length:0)&&function(e,t,r){if(t!=t)return function(e,t,r,n){var o=e.length,i=r+(n?1:-1);for(;n?i--:++i<o;)if(t(e[i],i,e))return i;return-1}(e,ye,r);var n=r-1,o=e.length;for(;++n<o;)if(e[n]===t)return n;return-1}(e,t,0)>-1}function fe(e,t,r){for(var n=-1,o=e?e.length:0;++n<o;)if(r(t,e[n]))return!0;return!1}function le(e,t){for(var r=-1,n=e?e.length:0,o=Array(n);++r<n;)o[r]=t(e[r],r,e);return o}function ye(e){return e!=e}function he(e){return function(t){return e(t)}}function pe(e,t){return e.has(t)}var ge,de=Array.prototype,be=Function.prototype,ve=Object.prototype,me=ce["__core-js_shared__"],je=(ge=/[^.]+$/.exec(me&&me.keys&&me.keys.IE_PROTO||""))?"Symbol(src)_1."+ge:"",_e=be.toString,we=ve.hasOwnProperty,Oe=ve.toString,$e=RegExp("^"+_e.call(we).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Se=de.splice,ke=Math.max,Ae=Math.min,Te=Je(ce,"Map"),Ne=Je(Object,"create");function xe(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function Ee(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function We(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function Ie(e){var t=-1,r=e?e.length:0;for(this.__data__=new We;++t<r;)this.add(e[t])}function Pe(e,t){for(var r,n,o=e.length;o--;)if((r=e[o][0])===(n=t)||r!=r&&n!=n)return o;return-1}function Me(e){return!(!Ce(e)||function(e){return!!je&&je in e}(e))&&(Re(e)||function(e){var t=!1;if(null!=e&&"function"!=typeof e.toString)try{t=!!(e+"")}catch(e){}return t}(e)?$e:ie).test(function(e){if(null!=e){try{return _e.call(e)}catch(e){}try{return e+""}catch(e){}}return""}(e))}function Fe(e){return function(e){return function(e){return!!e&&"object"==typeof e}(e)&&function(e){return null!=e&&function(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=re}(e.length)&&!Re(e)}(e)}(e)?e:[]}function De(e,t){var r,n,o=e.__data__;return("string"==(n=typeof(r=t))||"number"==n||"symbol"==n||"boolean"==n?"__proto__"!==r:null===r)?o["string"==typeof t?"string":"hash"]:o.map}function Je(e,t){var r=function(e,t){return null==e?void 0:e[t]}(e,t);return Me(r)?r:void 0}function Re(e){var t=Ce(e)?Oe.call(e):"";return t==ne||t==oe}function Ce(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}xe.prototype.clear=function(){this.__data__=Ne?Ne(null):{}},xe.prototype.delete=function(e){return this.has(e)&&delete this.__data__[e]},xe.prototype.get=function(e){var t=this.__data__;if(Ne){var r=t[e];return r===te?void 0:r}return we.call(t,e)?t[e]:void 0},xe.prototype.has=function(e){var t=this.__data__;return Ne?void 0!==t[e]:we.call(t,e)},xe.prototype.set=function(e,t){return this.__data__[e]=Ne&&void 0===t?te:t,this},Ee.prototype.clear=function(){this.__data__=[]},Ee.prototype.delete=function(e){var t=this.__data__,r=Pe(t,e);return!(r<0||(r==t.length-1?t.pop():Se.call(t,r,1),0))},Ee.prototype.get=function(e){var t=this.__data__,r=Pe(t,e);return r<0?void 0:t[r][1]},Ee.prototype.has=function(e){return Pe(this.__data__,e)>-1},Ee.prototype.set=function(e,t){var r=this.__data__,n=Pe(r,e);return n<0?r.push([e,t]):r[n][1]=t,this},We.prototype.clear=function(){this.__data__={hash:new xe,map:new(Te||Ee),string:new xe}},We.prototype.delete=function(e){return De(this,e).delete(e)},We.prototype.get=function(e){return De(this,e).get(e)},We.prototype.has=function(e){return De(this,e).has(e)},We.prototype.set=function(e,t){return De(this,e).set(e,t),this},Ie.prototype.add=Ie.prototype.push=function(e){return this.__data__.set(e,te),this},Ie.prototype.has=function(e){return this.__data__.has(e)};var Ve=function(e,t){return t=ke(void 0===t?e.length-1:t,0),function(){for(var r=arguments,n=-1,o=ke(r.length-t,0),i=Array(o);++n<o;)i[n]=r[t+n];n=-1;for(var a=Array(t+1);++n<t;)a[n]=r[n];return a[t]=i,function(e,t,r){switch(r.length){case 0:return e.call(t);case 1:return e.call(t,r[0]);case 2:return e.call(t,r[0],r[1]);case 3:return e.call(t,r[0],r[1],r[2])}return e.apply(t,r)}(e,this,a)}}(function(e){var t=le(e,Fe);return t.length&&t[0]===e[0]?function(e,t,r){for(var n=r?fe:se,o=e[0].length,i=e.length,a=i,u=Array(i),c=1/0,s=[];a--;){var f=e[a];a&&t&&(f=le(f,he(t))),c=Ae(f.length,c),u[a]=!r&&(t||o>=120&&f.length>=120)?new Ie(a&&f):void 0}f=e[0];var l=-1,y=u[0];e:for(;++l<o&&s.length<c;){var h=f[l],p=t?t(h):h;if(h=r||0!==h?h:0,!(y?pe(y,p):n(s,p,r))){for(a=i;--a;){var g=u[a];if(!(g?pe(g,p):n(e[a],p,r)))continue e}y&&y.push(p),s.push(h)}}return s}(t):[]});function He(e){return"string"==typeof e?e.length>0?[e]:[]:e}var Le=t(function(e){e.exports=function(){var e=Object.prototype.toString;function t(e,t){return null!=e&&Object.prototype.hasOwnProperty.call(e,t)}function r(e){if(!e)return!0;if(o(e)&&0===e.length)return!0;if("string"!=typeof e){for(var r in e)if(t(e,r))return!1;return!0}return!1}function n(t){return e.call(t)}var o=Array.isArray||function(t){return"[object Array]"===e.call(t)};function i(e){var t=parseInt(e);return t.toString()===e?t:e}function a(e){e=e||{};var a=function(e){return Object.keys(a).reduce(function(t,r){return"create"===r?t:("function"==typeof a[r]&&(t[r]=a[r].bind(a,e)),t)},{})};function u(r,n){return e.includeInheritedProps||"number"==typeof n&&Array.isArray(r)||t(r,n)}function c(e,t){if(u(e,t))return e[t]}function s(e,t,r,n){if("number"==typeof t&&(t=[t]),!t||0===t.length)return e;if("string"==typeof t)return s(e,t.split(".").map(i),r,n);var o=t[0],a=c(e,o);return 1===t.length?(void 0!==a&&n||(e[o]=r),a):(void 0===a&&("number"==typeof t[1]?e[o]=[]:e[o]={}),s(e[o],t.slice(1),r,n))}return a.has=function(r,n){if("number"==typeof n?n=[n]:"string"==typeof n&&(n=n.split(".")),!n||0===n.length)return!!r;for(var a=0;a<n.length;a++){var u=i(n[a]);if(!("number"==typeof u&&o(r)&&u<r.length||(e.includeInheritedProps?u in Object(r):t(r,u))))return!1;r=r[u]}return!0},a.ensureExists=function(e,t,r){return s(e,t,r,!0)},a.set=function(e,t,r,n){return s(e,t,r,n)},a.insert=function(e,t,r,n){var i=a.get(e,t);n=~~n,o(i)||(i=[],a.set(e,t,i)),i.splice(n,0,r)},a.empty=function(e,t){var i,c;if(!r(t)&&null!=e&&(i=a.get(e,t))){if("string"==typeof i)return a.set(e,t,"");if(function(e){return"boolean"==typeof e||"[object Boolean]"===n(e)}(i))return a.set(e,t,!1);if("number"==typeof i)return a.set(e,t,0);if(o(i))i.length=0;else{if(!function(e){return"object"==typeof e&&"[object Object]"===n(e)}(i))return a.set(e,t,null);for(c in i)u(i,c)&&delete i[c]}}},a.push=function(e,t){var r=a.get(e,t);o(r)||(r=[],a.set(e,t,r)),r.push.apply(r,Array.prototype.slice.call(arguments,2))},a.coalesce=function(e,t,r){for(var n,o=0,i=t.length;o<i;o++)if(void 0!==(n=a.get(e,t[o])))return n;return r},a.get=function(e,t,r){if("number"==typeof t&&(t=[t]),!t||0===t.length)return e;if(null==e)return r;if("string"==typeof t)return a.get(e,t.split("."),r);var n=i(t[0]),o=c(e,n);return void 0===o?r:1===t.length?o:a.get(e[n],t.slice(1),r)},a.del=function(e,t){if("number"==typeof t&&(t=[t]),null==e)return e;if(r(t))return e;if("string"==typeof t)return a.del(e,t.split("."));var n=i(t[0]);return u(e,n)?1!==t.length?a.del(e[n],t.slice(1)):(o(e)?e.splice(n,1):delete e[n],e):e},a}var u=a();return u.create=a,u.withInheritedProps=a({includeInheritedProps:!0}),u}()}),Ke=function(e){var t=(e=Math.abs(e))%100;if(t>=10&&t<=20)return"th";var r=e%10;return 1===r?"st":2===r?"nd":3===r?"rd":"th"};function qe(e){if("number"!=typeof e)throw new TypeError("Expected Number, got "+typeof e+" "+e);return Number.isFinite(e)?e+Ke(e):e}qe.indicator=Ke;var Ze=qe;const Be=/[|\\{}()[\]^$+*?.-]/g;var Ue=e=>{if("string"!=typeof e)throw new TypeError("Expected a string");return e.replace(Be,"\\$&")};const Ge=new Map;function ze(e,t){t={caseSensitive:!1,...t};const r=e+JSON.stringify(t);if(Ge.has(r))return Ge.get(r);const n="!"===e[0];n&&(e=e.slice(1)),e=Ue(e).replace(/\\\*/g,".*");const o=new RegExp(`^${e}$`,t.caseSensitive?"":"i");return o.negated=n,Ge.set(r,o),o}var Qe=(e,t,r)=>{if(!Array.isArray(e)||!Array.isArray(t))throw new TypeError(`Expected two arrays, got ${typeof e} ${typeof t}`);if(0===t.length)return e;const n="!"===t[0][0];t=t.map(e=>ze(e,r));const o=[];for(const r of e){let e=n;for(const n of t)n.test(r)&&(e=!n.negated);e&&o.push(r)}return o};function Xe(e,t,r){return function e(t,r,n,o=!0){const i=Object.prototype.hasOwnProperty;function a(e){return null!=e}function u(e){return"Object"===F(e)}function c(e,t){return t=He(t),Array.from(e).filter(e=>!t.some(t=>Qe.isMatch(e,t,{caseSensitive:!0})))}const s=["any","anything","every","everything","all","whatever","whatevs"],f=Array.isArray;if(!a(t))throw new Error("check-types-mini: [THROW_ID_01] First argument is missing!");const l={ignoreKeys:[],ignorePaths:[],acceptArrays:!1,acceptArraysIgnore:[],enforceStrictKeyset:!0,schema:{},msg:"check-types-mini",optsVarName:"opts"};let y;if(y=a(n)&&u(n)?Object.assign({},l,n):Object.assign({},l),a(y.ignoreKeys)&&y.ignoreKeys?y.ignoreKeys=He(y.ignoreKeys):y.ignoreKeys=[],a(y.ignorePaths)&&y.ignorePaths?y.ignorePaths=He(y.ignorePaths):y.ignorePaths=[],a(y.acceptArraysIgnore)&&y.acceptArraysIgnore?y.acceptArraysIgnore=He(y.acceptArraysIgnore):y.acceptArraysIgnore=[],y.msg="string"==typeof y.msg?y.msg.trim():y.msg,":"===y.msg[y.msg.length-1]&&(y.msg=y.msg.slice(0,y.msg.length-1).trim()),y.schema&&(Object.keys(y.schema).forEach(e=>{if(u(y.schema[e])){const t={};ee(y.schema[e],(r,n,o)=>{const i=void 0!==n?n:r;return f(i)||u(i)||(t[`${e}.${o.path}`]=i),i}),delete y.schema[e],y.schema=Object.assign(y.schema,t)}}),Object.keys(y.schema).forEach(e=>{f(y.schema[e])||(y.schema[e]=[y.schema[e]]),y.schema[e]=y.schema[e].map(String).map(e=>e.toLowerCase()).map(e=>e.trim())})),a(r)||(r={}),o&&e(y,l,{enforceStrictKeyset:!1},!1),y.enforceStrictKeyset)if(a(y.schema)&&Object.keys(y.schema).length>0){if(0!==c(H(Object.keys(t),Object.keys(r).concat(Object.keys(y.schema))),y.ignoreKeys).length){const e=H(Object.keys(t),Object.keys(r).concat(Object.keys(y.schema)));throw new TypeError(`${y.msg}: ${y.optsVarName}.enforceStrictKeyset is on and the following key${e.length>1?"s":""} ${e.length>1?"are":"is"} not covered by schema and/or reference objects: ${e.join(", ")}`)}}else{if(!(a(r)&&Object.keys(r).length>0))throw new TypeError(`${y.msg}: Both ${y.optsVarName}.schema and reference objects are missing! We don't have anything to match the keys as you requested via opts.enforceStrictKeyset!`);if(0!==c(H(Object.keys(t),Object.keys(r)),y.ignoreKeys).length){const e=H(Object.keys(t),Object.keys(r));throw new TypeError(`${y.msg}: The input object has key${e.length>1?"s":""} which ${e.length>1?"are":"is"} not covered by the reference object: ${e.join(", ")}`)}if(0!==c(H(Object.keys(r),Object.keys(t)),y.ignoreKeys).length){const e=H(Object.keys(r),Object.keys(t));throw new TypeError(`${y.msg}: The reference object has key${e.length>1?"s":""} which ${e.length>1?"are":"is"} not present in the input object: ${e.join(", ")}`)}}const h=[];ee(t,(e,n,o)=>{let a=n,c=e;if("array"===o.parentType&&(c=void 0,a=e),f(h)&&h.length&&h.some(e=>o.path.startsWith(e)))return a;if(c&&y.ignoreKeys.some(e=>Qe.isMatch(c,e)))return a;if(y.ignorePaths.some(e=>Qe.isMatch(o.path,e)))return a;const l=!(!u(a)&&!f(a)&&f(o.parent));let p=!1;u(y.schema)&&i.call(y.schema,Le.get(o.path))&&(p=!0);let g=!1;if(u(r)&&Le.has(r,Le.get(o.path))&&(g=!0),y.enforceStrictKeyset&&l&&!p&&!g)throw new TypeError(`${y.msg}: ${y.optsVarName}.${o.path} is neither covered by reference object (second input argument), nor ${y.optsVarName}.schema! To stop this error, turn off ${y.optsVarName}.enforceStrictKeyset or provide some type reference (2nd argument or ${y.optsVarName}.schema).\n\nDebug info:\n\nobj = ${JSON.stringify(t,null,4)}\n\nref = ${JSON.stringify(r,null,4)}\n\ninnerObj = ${JSON.stringify(o,null,4)}\n\nopts = ${JSON.stringify(y,null,4)}\n\ncurrent = ${JSON.stringify(a,null,4)}\n\n`);if(p){const e=He(y.schema[o.path]).map(String).map(e=>e.toLowerCase());if(Le.set(y.schema,o.path,e),Ve(e,s).length)h.push(o.path);else if(!0!==a&&!1!==a&&!e.includes(F(a).toLowerCase())||(!0===a||!1===a)&&!e.includes(String(a))&&!e.includes("boolean")){if(!f(a)||!y.acceptArrays)throw new TypeError(`${y.msg}: ${y.optsVarName}.${o.path} was customised to ${"string"!==F(a)?'"':""}${JSON.stringify(a,null,0)}${"string"!==F(a)?'"':""} (type: ${F(a).toLowerCase()}) which is not among the allowed types in schema (which is equal to ${JSON.stringify(e,null,0)})`);for(let t=0,r=a.length;t<r;t++)if(!e.includes(F(a[t]).toLowerCase()))throw new TypeError(`${y.msg}: ${y.optsVarName}.${o.path}.${t}, the ${Ze(t+1)} element (equal to ${JSON.stringify(a[t],null,0)}) is of a type ${F(a[t]).toLowerCase()}, but only the following are allowed by the ${y.optsVarName}.schema: ${e.join(", ")}`)}}else if(g){const t=Le.get(r,o.path);if(y.acceptArrays&&f(a)&&!y.acceptArraysIgnore.includes(e)){if(!a.every(t=>F(t).toLowerCase()===F(r[e]).toLowerCase()))throw new TypeError(`${y.msg}: ${y.optsVarName}.${o.path} was customised to be array, but not all of its elements are ${F(r[e]).toLowerCase()}-type`)}else if(F(a)!==F(t))throw new TypeError(`${y.msg}: ${y.optsVarName}.${o.path} was customised to ${"string"===F(a).toLowerCase()?"":'"'}${JSON.stringify(a,null,0)}${"string"===F(a).toLowerCase()?"":'"'} which is not ${F(t).toLowerCase()} but ${F(a).toLowerCase()}`)}return a})}(e,t,r)}function Ye(e,t){function r(e){return null!=e}if(!r(e))throw new Error(`util-array-object-or-both/validate(): [THROW_ID_01] Please provide a string to work on. Currently it's equal to ${JSON.stringify(e,null,4)}`);if("string"!=typeof e)throw new Error(`util-array-object-or-both/validate(): [THROW_ID_02] Input must be string! Currently it's ${typeof e}, equal to: ${JSON.stringify(e,null,4)}`);if(r(t)&&!Q(t))throw new Error(`util-array-object-or-both/validate(): [THROW_ID_03] Second argument, options object, must be, well, object! Currenlty it's: ${typeof t}, equal to: ${JSON.stringify(t,null,4)}`);const n={msg:"",optsVarName:"given variable"},o=Object.assign({},n,t);if(Xe(o,n,{msg:"util-array-object-or-both/validate(): [THROW_ID_03]",optsVarName:"opts",schema:{msg:["string",null],optsVarName:["string",null]}}),r(o.msg)&&o.msg.length>0&&(o.msg=`${o.msg.trim()} `),"given variable"!==o.optsVarName&&(o.optsVarName=`variable "${o.optsVarName}"`),M(["object","objects","obj","ob","o"],e.toLowerCase().trim()))return"object";if(M(["array","arrays","arr","aray","arr","a"],e.toLowerCase().trim()))return"array";if(M(["any","all","everything","both","either","each","whatever","whatevs","e"],e.toLowerCase().trim()))return"any";throw new TypeError(`${o.msg}The ${o.optsVarName} was customised to an unrecognised value: ${e}. Please check it against the API documentation.`)}Qe.isMatch=(e,t,r)=>{const n=ze(t,r),o=n.test(e);return n.negated?!o:o};var et=function(e,t){if(t){if("object"!=typeof t)throw new TypeError(String(t)+" is not an object. Expected an object that has boolean `includeZero` property.");if("includeZero"in t){if("boolean"!=typeof t.includeZero)throw new TypeError(String(t.includeZero)+" is neither true nor false. `includeZero` option must be a Boolean value.");if(t.includeZero&&0===e)return!0}}return Number.isSafeInteger(e)&&e>=1},tt=1/0,rt="[object Symbol]",nt=/^\s+|\s+$/g,ot="[\\ud800-\\udfff]",it="[\\u0300-\\u036f\\ufe20-\\ufe23\\u20d0-\\u20f0]",at="\\ud83c[\\udffb-\\udfff]",ut="[^\\ud800-\\udfff]",ct="(?:\\ud83c[\\udde6-\\uddff]){2}",st="[\\ud800-\\udbff][\\udc00-\\udfff]",ft="(?:"+it+"|"+at+")"+"?",lt="[\\ufe0e\\ufe0f]?"+ft+("(?:\\u200d(?:"+[ut,ct,st].join("|")+")[\\ufe0e\\ufe0f]?"+ft+")*"),yt="(?:"+[ut+it+"?",it,ct,st,ot].join("|")+")",ht=RegExp(at+"(?="+at+")|"+yt+lt,"g"),pt=RegExp("[\\u200d\\ud800-\\udfff\\u0300-\\u036f\\ufe20-\\ufe23\\u20d0-\\u20f0\\ufe0e\\ufe0f]"),gt="object"==typeof e&&e&&e.Object===Object&&e,dt="object"==typeof self&&self&&self.Object===Object&&self,bt=gt||dt||Function("return this")();function vt(e,t,r){if(t!=t)return function(e,t,r,n){for(var o=e.length,i=r+(n?1:-1);n?i--:++i<o;)if(t(e[i],i,e))return i;return-1}(e,mt,r);for(var n=r-1,o=e.length;++n<o;)if(e[n]===t)return n;return-1}function mt(e){return e!=e}function jt(e){return function(e){return pt.test(e)}(e)?function(e){return e.match(ht)||[]}(e):function(e){return e.split("")}(e)}var _t=Object.prototype.toString,wt=bt.Symbol,Ot=wt?wt.prototype:void 0,$t=Ot?Ot.toString:void 0;function St(e){if("string"==typeof e)return e;if(function(e){return"symbol"==typeof e||function(e){return!!e&&"object"==typeof e}(e)&&_t.call(e)==rt}(e))return $t?$t.call(e):"";var t=e+"";return"0"==t&&1/e==-tt?"-0":t}function kt(e,t,r){var n=e.length;return r=void 0===r?n:r,!t&&r>=n?e:function(e,t,r){var n=-1,o=e.length;t<0&&(t=-t>o?0:o+t),(r=r>o?o:r)<0&&(r+=o),o=t>r?0:r-t>>>0,t>>>=0;for(var i=Array(o);++n<o;)i[n]=e[n+t];return i}(e,t,r)}var At=function(e,t,r){var n;if((e=null==(n=e)?"":St(n))&&(r||void 0===t))return e.replace(nt,"");if(!e||!(t=St(t)))return e;var o=jt(e),i=jt(t);return kt(o,function(e,t){for(var r=-1,n=e.length;++r<n&&vt(t,e[r],0)>-1;);return r}(o,i),function(e,t){for(var r=e.length;r--&&vt(t,e[r],0)>-1;);return r}(o,i)+1).join("")};function Tt(e){function t(e){return"string"==typeof e}const r=Array.isArray;let n=!0;return!!(r(e)||Q(e)||t(e))&&(t(e)?0===At(e).length:(e=ee(e,(e,r)=>{const o=void 0!==r?r:e;return t(o)&&""!==At(o)&&(n=!1),o}),n))}const Nt=Array.isArray;function xt(e){return null!=e}function Et(e){return"Object"===F(e)}function Wt(e){return"string"===F(e)}function It(e){return Et(e)||Wt(e)||function(e){return"number"===F(e)}(e)||function(e){return"boolean"===F(e)}(e)||Nt(e)||function(e){return null===e}(e)}const Pt=Array.isArray;function Mt(e,t,n){if(void 0===e)throw new TypeError("ast-compare/compare(): [THROW_ID_01] first argument is missing!");if(void 0===t)throw new TypeError("ast-compare/compare(): [THROW_ID_02] second argument is missing!");if(xt(e)&&!It(e))throw new TypeError(`ast-compare/compare(): [THROW_ID_03] first input argument is of a wrong type, ${F(e)}, equal to: ${JSON.stringify(e,null,4)}`);if(xt(t)&&!It(t))throw new TypeError(`ast-compare/compare(): [THROW_ID_04] second input argument is of a wrong type, ${F(t)}, equal to: ${JSON.stringify(t,null,4)}`);if(xt(n)&&!Et(n))throw new TypeError(`ast-compare/compare(): [THROW_ID_05] third argument, options object, must, well, be an object! Currently it's: ${F(n)} and equal to: ${JSON.stringify(n,null,4)}`);const o=r(t),i=r(e);let a,u,c,s=0;const f={hungryForWhitespace:!1,matchStrictly:!1,verboseWhenMismatches:!1,useWildcards:!1},l=Object.assign({},f,n);if(Xe(l,f,{msg:"ast-compare/compare(): [THROW_ID_06*]"}),l.hungryForWhitespace&&l.matchStrictly&&Et(e)&&Tt(e)&&Et(t)&&0===Object.keys(t).length)return!0;if((!l.hungryForWhitespace||l.hungryForWhitespace&&!Tt(e)&&Tt(t))&&Et(e)&&0!==Object.keys(e).length&&Et(t)&&0===Object.keys(t).length||F(e)!==F(t)&&(!l.hungryForWhitespace||l.hungryForWhitespace&&!Tt(e)))return!1;if(Wt(i)&&Wt(o))return!!(l.hungryForWhitespace&&Tt(i)&&Tt(o))||(l.verboseWhenMismatches?i===o||`Given string ${o} is not matched! We have ${i} on the other end.`:l.useWildcards?Qe.isMatch(i,o,{caseSensitive:!0}):i===o);if(Pt(i)&&Pt(o)){if(l.hungryForWhitespace&&Tt(o)&&(!l.matchStrictly||l.matchStrictly&&i.length===o.length))return!0;if(!l.hungryForWhitespace&&o.length>i.length||l.matchStrictly&&o.length!==i.length)return!!l.verboseWhenMismatches&&`The length of a given array, ${JSON.stringify(o,null,4)} is ${o.length} but the length of an array on the other end, ${JSON.stringify(i,null,4)} is ${i.length}`;if(0===o.length)return 0===i.length||!!l.verboseWhenMismatches&&`The given array has no elements, but the array on the other end, ${JSON.stringify(i,null,4)} does have some`;for(let e=0,t=o.length;e<t;e++){c=!1;for(let t=s,r=i.length;t<r;t++)if(s+=1,!0===Mt(i[t],o[e],l)){c=!0;break}if(!c)return!!l.verboseWhenMismatches&&`The given array ${JSON.stringify(o,null,4)} is not a subset of an array on the other end, ${JSON.stringify(i,null,4)}`}}else{if(!Et(i)||!Et(o))return!!(l.hungryForWhitespace&&Tt(i)&&Tt(o)&&(!l.matchStrictly||l.matchStrictly&&(y=o,Et(y)?0===Object.keys(y).length:(Nt(y)||Wt(y))&&0===y.length)))||i===o;if(a=Object.keys(o),u=Object.keys(i),l.matchStrictly&&a.length!==u.length){if(!l.verboseWhenMismatches)return!1;const e=H(r(a),r(u)),t=e.length>0?`First object has unique keys: ${JSON.stringify(e,null,4)}.`:"",n=H(r(u),r(a));return`When matching strictly, we found that both objects have different amount of keys. ${t} ${n.length>0?`Second object has unique keys:\n ${JSON.stringify(n,null,4)}.`:""}`}for(let e=0,t=a.length;e<t;e++){if(!xt(i[a[e]]))return!l.useWildcards||l.useWildcards&&!a[e].includes("*")?!!l.verboseWhenMismatches&&`The given object has key ${a[e]} which the other-one does not have.`:!!Object.keys(i).some(t=>Qe.isMatch(t,a[e],{caseSensitive:!0}))||!!l.verboseWhenMismatches&&`The given object has key ${a[e]} which the other-one does not have.`;if(void 0!==i[a[e]]&&!It(i[a[e]]))throw new TypeError(`ast-compare/compare(): [THROW_ID_07] The input ${JSON.stringify(i,null,4)} contains a value of a wrong type, ${F(i[a[e]])} at index ${e}, equal to: ${JSON.stringify(i[a[e]],null,4)}`);if(!It(o[a[e]]))throw new TypeError(`ast-compare/compare(): [THROW_ID_08] The input ${JSON.stringify(o,null,4)} contains a value of a wrong type, ${F(o[a[e]])} at index ${e}, equal to: ${JSON.stringify(o[a[e]],null,4)}`);if(xt(i[a[e]])&&F(i[a[e]])!==F(o[a[e]])){if(!(Tt(i[a[e]])&&Tt(o[a[e]])&&l.hungryForWhitespace))return!!l.verboseWhenMismatches&&`The given key ${a[e]} is of a different type on both objects. On the first-one, it's ${F(o[a[e]])}, on the second-one, it's ${F(i[a[e]])}`}else if(!0!==Mt(i[a[e]],o[a[e]],l))return!!l.verboseWhenMismatches&&`The given piece ${JSON.stringify(o[a[e]],null,4)} and ${JSON.stringify(i[a[e]],null,4)} don't match.`}}var y;return!0}function Ft(e){return null!=e}function Dt(e){return void 0!==e}function Jt(e,t){return F(e)===F(t)&&Mt(e,t,{matchStrictly:!0,useWildcards:!0})}function Rt(e,t){if(!Ft(e))throw new Error("ast-monkey/main.js/monkey(): Please provide an input");let n=r(e);(t=Object.assign({key:null,val:void 0},t)).mode;const o={count:0,gatherPath:[],finding:null},i=[];let a=!1,u=!1;return Ft(t.key)&&!Dt(t.val)&&(a=!0),!Ft(t.key)&&Dt(t.val)&&(u=!0),t.mode,t.mode,"arrayFirstOnly"===t.mode&&Array.isArray(n)&&n.length>0&&(n=[n[0]]),n=ee(n,(e,n,c)=>{let s;if(o.count+=1,t.mode,t.mode,t.mode,o.gatherPath.length=c.depth,o.gatherPath.push(o.count),t.mode,"get"===t.mode)o.count===t.index&&(Dt(n)?(o.finding={},o.finding[e]=n):o.finding=e);else if("find"===t.mode||"del"===t.mode){if(!("any"===t.only||"array"===t.only&&void 0===n||"object"===t.only&&void 0!==n)||!(a&&Jt(e,t.key)||u&&Jt(n,t.val)||!a&&!u&&Jt(e,t.key)&&Jt(n,t.val)))return void 0!==n?n:e;if("find"!==t.mode)return NaN;(s={}).index=o.count,s.key=e,s.val=n,s.path=r(o.gatherPath),i.push(s)}return t.mode,"set"===t.mode&&o.count===t.index?t.val:"drop"===t.mode&&o.count===t.index?NaN:"arrayFirstOnly"===t.mode?Dt(n)&&Array.isArray(n)?[n[0]]:Ft(e)&&Array.isArray(e)?[e[0]]:void 0!==n?n:e:void 0!==n?n:e}),"get"===t.mode?o.finding:"find"===t.mode?i.length>0?i:null:n}function Ct(e,t){if(!Dt(t.key)&&!Dt(t.val))throw new Error("ast-monkey/main.js/find(): Please provide opts.key or opts.val");return Xe(t,null,{schema:{key:["null","string"],val:"any",only:["undefined","null","string"]}}),"string"==typeof t.only&&t.only.length>0?t.only=Ye(t.only,{msg:"ast-monkey/find():",optsVarName:"opts.only"}):t.only="any",Rt(e,Object.assign({},t,{mode:"find"}))}function Vt(e,t){if(!Ft(t.index))throw new Error("ast-monkey/main.js/get(): Please provide opts.index");if("string"==typeof t.index){if(!et(parseFloat(t.index,10),{includeZero:!0}))throw new Error(`ast-monkey/main.js/get(): opts.index must be a natural number. It was given as: ${t.index}`);t.index=parseInt(t.index,10)}if(Xe(t,null,{schema:{index:"number"}}),!et(t.index,{includeZero:!0}))throw new Error(`ast-monkey/main.js/get(): opts.index must be a natural number. It was given as: ${t.index}`);return Rt(e,Object.assign({},t,{mode:"get"}))}function Ht(e,t){if(!Ft(t.index))throw new Error("ast-monkey/main.js/drop(): Please provide opts.index");if("string"==typeof t.index){if(!et(parseFloat(t.index,10),{includeZero:!0}))throw new Error(`ast-monkey/main.js/drop(): opts.index must be a natural number. It was given as: ${t.index}`);t.index=parseInt(t.index,10)}if(!et(t.index,{includeZero:!0}))throw new Error(`ast-monkey/main.js/get(): opts.index must be a natural number. It was given as: ${t.index}`);return Xe(t,null,{schema:{index:"number"}}),Rt(e,Object.assign({},t,{mode:"drop"}))}function Lt(e,t){if(!Ft(t.key)&&!Dt(t.val))throw new Error("ast-monkey/main.js/del(): Please provide opts.key or opts.val");return Xe(t,null,{schema:{key:[null,"string"],val:"any",only:["undefined","null","string"]}}),"string"==typeof t.only&&t.only.length>0?t.only=Ye(t.only,{msg:"ast-monkey/del():",optsVarName:"opts.only"}):t.only="any",Rt(e,Object.assign({},t,{mode:"del"}))}function Kt(e){let t,r,n=!0;if(Array.isArray(e)){if(0===e.length)return!0;for(t=0,r=e.length;t<r;t++){if(null===(n=Kt(e[t])))return null;if(!n)return!1}}else if(Q(e)){if(0===Object.keys(e).length)return!0;for(t=0,r=Object.keys(e).length;t<r;t++){if(null===(n=Kt(e[Object.keys(e)[t]])))return null;if(!n)return!1}}else{if("string"!=typeof e)return null;if(0!==e.length)return!1}return n}return function(e,t){function n(e){return null!=e}if(!n(e))throw new Error("object-delete-key/deleteKey(): [THROW_ID_01] Please provide the first argument, something to work upon.");if(arguments.length>2)throw new Error("object-delete-key/deleteKey(): [THROW_ID_02] Third argument detected! Computer does not like this...");var o={key:null,val:void 0,cleanup:!0,only:"any"},i=Object.assign({},o,t);if(Xe(i,o,{msg:"object-delete-key/deleteKey(): [THROW_ID_00*]",ignorePaths:"val.*",schema:{key:["null","string"],val:"whatever"}}),i.only=Ye(i.only,{msg:"object-delete-key/deleteKey(): [THROW_ID_03]",optsVarName:"opts.only"}),!n(i.key)&&!n(i.val))throw new Error("object-delete-key/deleteKey(): [THROW_ID_04] Please provide at least a key or a value.");var a=r(e);if(i.cleanup){for(var u,c,s=Ct(a,{key:i.key,val:i.val,only:i.only});s;){c=s[0].index;for(var f=1,l=s[0].path.length;f<l;f++)Kt(Lt(Vt(a,{index:u=s[0].path[l-1-f]}),{key:i.key,val:i.val,only:i.only}))&&(c=u);s=Ct(a=Ht(a,{index:c}),{key:i.key,val:i.val,only:i.only})}return a}return Lt(a,{key:i.key,val:i.val,only:i.only})}});
{
"name": "object-delete-key",
"version": "1.8.21",
"version": "1.8.22",
"description": "Delete keys from all arrays or plain objects, nested within anything, by key or by value or by both, and clean up afterwards. Accepts wildcards.",

@@ -16,2 +16,20 @@ "license": "MIT",

},
"keywords": [
"ast",
"by",
"delete",
"drop",
"from",
"html",
"key",
"object",
"plain",
"parser",
"posthtml",
"posthtml-tree",
"posthtmltree",
"tree",
"xml",
"value"
],
"main": "dist/object-delete-key.cjs.js",

@@ -34,2 +52,7 @@ "module": "dist/object-delete-key.esm.js",

},
"husky": {
"hooks": {
"pre-commit": "npm run format && npm test"
}
},
"ava": {

@@ -47,25 +70,2 @@ "compileEnhancements": false,

},
"husky": {
"hooks": {
"pre-commit": "npm run format && npm test"
}
},
"keywords": [
"ast",
"by",
"delete",
"drop",
"from",
"html",
"key",
"object",
"plain",
"parser",
"posthtml",
"posthtml-tree",
"posthtmltree",
"tree",
"xml",
"value"
],
"lect": {

@@ -176,36 +176,36 @@ "babelrc": {

"dependencies": {
"ast-is-empty": "^1.9.21",
"ast-monkey": "^7.10.21",
"check-types-mini": "^5.7.17",
"ast-is-empty": "^1.9.22",
"ast-monkey": "^7.10.22",
"check-types-mini": "^5.7.18",
"lodash.clonedeep": "^4.5.0",
"util-array-object-or-both": "^2.7.21"
"util-array-object-or-both": "^2.7.22"
},
"devDependencies": {
"@babel/core": "^7.4.3",
"@babel/preset-env": "^7.4.3",
"@babel/register": "^7.4.0",
"ava": "^1.4.1",
"babel-plugin-istanbul": "^5.1.1",
"@babel/core": "^7.4.5",
"@babel/preset-env": "^7.4.5",
"@babel/register": "^7.4.4",
"ava": "^2.0.0",
"babel-plugin-istanbul": "^5.1.4",
"eslint": "^5.16.0",
"eslint-config-prettier": "^4.1.0",
"eslint-plugin-ava": "^6.0.0",
"eslint-plugin-import": "^2.16.0",
"eslint-config-prettier": "^4.3.0",
"eslint-plugin-ava": "^7.0.0",
"eslint-plugin-import": "^2.17.3",
"eslint-plugin-no-unsanitized": "^3.0.2",
"eslint-plugin-prettier": "^3.0.1",
"js-row-num-cli": "^1.5.21",
"lect": "^0.5.15",
"nyc": "^13.3.0",
"eslint-plugin-prettier": "^3.1.0",
"js-row-num-cli": "^1.5.22",
"lect": "^0.6.0",
"nyc": "^14.1.1",
"posthtml-parser": "^0.4.1",
"prettier": "^1.16.4",
"rollup": "^1.9.0",
"prettier": "^1.17.1",
"rollup": "^1.13.1",
"rollup-plugin-ascii": "^0.0.3",
"rollup-plugin-babel": "^4.3.2",
"rollup-plugin-cleanup": "^3.1.1",
"rollup-plugin-commonjs": "^9.3.4",
"rollup-plugin-commonjs": "^10.0.0",
"rollup-plugin-json": "^4.0.0",
"rollup-plugin-license": "^0.8.1",
"rollup-plugin-node-resolve": "^4.2.1",
"rollup-plugin-node-resolve": "^5.0.1",
"rollup-plugin-strip": "^1.2.1",
"rollup-plugin-terser": "^4.0.4"
"rollup-plugin-terser": "^5.0.0"
}
}

@@ -317,5 +317,5 @@ # object-delete-key

- If you see an error, [raise an issue](https://gitlab.com/codsen/codsen/issues/new?issue[title]=object-delete-key%20package%20-%20put%20title%20here&issue[description]=%23%23%20object-delete-key%0A%0Aput%20description%20here).
- If you want a new feature but can't code it up yourself, also [raise an issue](https://gitlab.com/codsen/codsen/issues/new?issue[title]=object-delete-key%20package%20-%20put%20title%20here&issue[description]=%23%23%20object-delete-key%0A%0Aput%20description%20here). Let's discuss it.
- If you tried to use this package, but something didn't work out, also [raise an issue](https://gitlab.com/codsen/codsen/issues/new?issue[title]=object-delete-key%20package%20-%20put%20title%20here&issue[description]=%23%23%20object-delete-key%0A%0Aput%20description%20here). We'll try to help.
- If you see an error, [raise an issue](<https://gitlab.com/codsen/codsen/issues/new?issue[title]=object-delete-key%20package%20-%20put%20title%20here&issue[description]=**Which%20package%20is%20this%20issue%20for**%3A%20%0Aobject-delete-key%0A%0A**Describe%20the%20issue%20(if%20necessary)**%3A%20%0A%0A%0A%2Fassign%20%40revelt>).
- If you want a new feature but can't code it up yourself, also [raise an issue](<https://gitlab.com/codsen/codsen/issues/new?issue[title]=object-delete-key%20package%20-%20put%20title%20here&issue[description]=**Which%20package%20is%20this%20issue%20for**%3A%20%0Aobject-delete-key%0A%0A**Describe%20the%20issue%20(if%20necessary)**%3A%20%0A%0A%0A%2Fassign%20%40revelt>). Let's discuss it.
- If you tried to use this package, but something didn't work out, also [raise an issue](<https://gitlab.com/codsen/codsen/issues/new?issue[title]=object-delete-key%20package%20-%20put%20title%20here&issue[description]=**Which%20package%20is%20this%20issue%20for**%3A%20%0Aobject-delete-key%0A%0A**Describe%20the%20issue%20(if%20necessary)**%3A%20%0A%0A%0A%2Fassign%20%40revelt>). We'll try to help.
- If you want to contribute some code, fork the [monorepo](https://gitlab.com/codsen/codsen/) via GitLab, then write code, then file a pull request on GitLab. We'll merge it in and release.

@@ -322,0 +322,0 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc