@feathersjs/client 4.5.16 → 4.5.18

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/core.min.js CHANGED
@@ -1 +1 @@
1
- !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.feathers=t():e.feathers=t()}(this,(function(){return e={898:function(e,t,n){var r;t.formatArgs=function(t){var n,r,o;t[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+t[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff),this.useColors&&(n="color: "+this.color,t.splice(1,0,n,"color: inherit"),t[o=r=0].replace(/%[a-zA-Z%]/g,(function(e){"%%"!==e&&(r++,"%c"===e)&&(o=r)})),t.splice(o,0,n))},t.save=function(e){try{e?t.storage.setItem("debug",e):t.storage.removeItem("debug")}catch(e){}},t.load=function(){var e;try{e=t.storage.getItem("debug")}catch(e){}return!e&&"undefined"!=typeof process&&"env"in process&&(e=process.env.DEBUG),e},t.useColors=function(){return!("undefined"==typeof window||!window.process||"renderer"!==window.process.type&&!window.process.__nwjs)||("undefined"==typeof navigator||!navigator.userAgent||!navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))&&("undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&31<=parseInt(RegExp.$1,10)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))},t.storage=function(){try{return localStorage}catch(e){}}(),t.destroy=(r=!1,function(){r||(r=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."))}),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],t.log=console.debug||console.log||function(){},e.exports=n(604)(t),e.exports.formatters.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}},604:function(e,t,n){function r(e){return function(e){if(Array.isArray(e))return o(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){var n;if(e)return"string"==typeof e?o(e,t):"Map"===(n="Object"===(n=Object.prototype.toString.call(e).slice(8,-1))&&e.constructor?e.constructor.name:n)||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?o(e,t):void 0}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function o(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}e.exports=function(e){function t(e){var n,r,i,s=null;function c(){for(var e,r,o,i,s=arguments.length,a=new Array(s),u=0;u<s;u++)a[u]=arguments[u];c.enabled&&(e=c,o=(r=Number(new Date))-(n||r),e.diff=o,e.prev=n,e.curr=r,n=r,a[0]=t.coerce(a[0]),"string"!=typeof a[0]&&a.unshift("%O"),a[i=0]=a[0].replace(/%([a-zA-Z%])/g,(function(n,r){return"%%"===n?"%":(i++,"function"==typeof(r=t.formatters[r])&&(o=a[i],n=r.call(e,o),a.splice(i,1),i--),n);var o})),t.formatArgs.call(e,a),(e.log||t.log).apply(e,a))}return c.namespace=e,c.useColors=t.useColors(),c.color=t.selectColor(e),c.extend=o,c.destroy=t.destroy,Object.defineProperty(c,"enabled",{enumerable:!0,configurable:!1,get:function(){return null!==s?s:(r!==t.namespaces&&(r=t.namespaces,i=t.enabled(e)),i)},set:function(e){s=e}}),"function"==typeof t.init&&t.init(c),c}function o(e,n){return(n=t(this.namespace+(void 0===n?":":n)+e)).log=this.log,n}function i(e){return e.toString().substring(2,e.toString().length-2).replace(/\.\*\?$/,"*")}return((t.debug=t).default=t).coerce=function(e){return e instanceof Error?e.stack||e.message:e},t.disable=function(){var e=[].concat(r(t.names.map(i)),r(t.skips.map(i).map((function(e){return"-"+e})))).join(",");return t.enable(""),e},t.enable=function(e){t.save(e),t.namespaces=e,t.names=[],t.skips=[];var n,r=("string"==typeof e?e:"").split(/[\s,]+/),o=r.length;for(n=0;n<o;n++)r[n]&&("-"===(e=r[n].replace(/\*/g,".*?"))[0]?t.skips.push(new RegExp("^"+e.slice(1)+"$")):t.names.push(new RegExp("^"+e+"$")))},t.enabled=function(e){if("*"===e[e.length-1])return!0;var n,r;for(n=0,r=t.skips.length;n<r;n++)if(t.skips[n].test(e))return!1;for(n=0,r=t.names.length;n<r;n++)if(t.names[n].test(e))return!0;return!1},t.humanize=n(378),t.destroy=function(){console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")},Object.keys(e).forEach((function(n){t[n]=e[n]})),t.names=[],t.skips=[],t.formatters={},t.selectColor=function(e){for(var n=0,r=0;r<e.length;r++)n=(n<<5)-n+e.charCodeAt(r),n|=0;return t.colors[Math.abs(n)%t.colors.length]},t.enable(t.load()),t}},630:function(e,t,n){e.exports=n(845)},196:function(e,t,n){"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.enableHooks=t.processHooks=t.getHooks=t.isHookObject=t.convertHookData=t.makeArguments=t.defaultMakeArguments=t.createHookObject=t.ACTIVATE_HOOKS=void 0;var o=(n=n(541))._,i=o.each,s=o.pick;function c(e){var t=[];return void 0!==e.id&&t.push(e.id),e.data&&t.push(e.data),t.push(e.params||{}),t}function a(e){var t={};return Array.isArray(e)?t={all:e}:"object"!==r(e)?t={all:[e]}:i(e,(function(e,n){t[n]=Array.isArray(e)?e:[e]})),t}function u(e){return"object"===r(e)&&"string"==typeof e.method&&"string"==typeof e.type}t.ACTIVATE_HOOKS=(0,n.createSymbol)("__feathersActivateHooks"),t.createHookObject=function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},n={};return Object.defineProperty(n,"toJSON",{value:function(){return s(this,"type","method","path","params","id","data","result","error")}}),Object.assign(n,t,{method:e,get path(){var e=t.app,n=t.service;return n&&e&&e.services?Object.keys(e.services).find((function(t){return e.services[t]===n})):null}})},t.defaultMakeArguments=c,t.makeArguments=function(e){switch(e.method){case"find":return[e.params];case"get":case"remove":return[e.id,e.params];case"update":case"patch":return[e.id,e.data,e.params];case"create":return[e.data,e.params]}return c(e)},t.convertHookData=a,t.isHookObject=u,t.getHooks=function(e,t,n,r){return e=e.__hooks[n][r]||[],t=t.__hooks[n][r]||[],4<arguments.length&&void 0!==arguments[4]&&arguments[4]?t.concat(e):e.concat(t)},t.processHooks=function(e,t){function n(e){if(e){if(!u(e))throw new Error("".concat(o.type," hook for '").concat(o.method,"' method returned invalid hook object"));o=e}return o}var r=this,o=t;return e.reduce((function(e,t){var o=t.bind(r);return e.then((function(e){return o(e)})).then(n)}),Promise.resolve(o)).then((function(){return o})).catch((function(e){throw e.hook=o,e}))},t.enableHooks=function(e,t,n){var r;return"function"==typeof e.hooks?e:(r={},n.forEach((function(e){r[e]={}})),Object.defineProperty(e,"__hooks",{configurable:!0,value:r,writable:!0}),Object.assign(e,{hooks:function(e){var n=this;return i(e,(function(e,r){if(!n.__hooks[r])throw new Error("'".concat(r,"' is not a valid hook type"));var o=a(e);i(o,(function(e,n){if("all"!==n&&-1===t.indexOf(n))throw new Error("'".concat(n,"' is not a valid hook method"))})),t.forEach((function(e){var t=n.__hooks[r][e]||(n.__hooks[r][e]=[]);o.all&&t.push.apply(t,o.all),o[e]&&t.push.apply(t,o[e])}))})),this}}))}},575:function(e,t,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n);var o=Object.getOwnPropertyDescriptor(t,n);o&&("get"in o?t.__esModule:!o.writable&&!o.configurable)||(o={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,o)}:function(e,t,n,r){e[r=void 0===r?n:r]=t[n]}),o=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),i=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)"default"!==n&&Object.prototype.hasOwnProperty.call(e,n)&&r(t,e,n);return o(t,e),t},s=this&&this.__exportStar||function(e,t){for(var n in e)"default"===n||Object.prototype.hasOwnProperty.call(t,n)||r(t,e,n)};Object.defineProperty(t,"__esModule",{value:!0}),t.hooks=void 0,i=i(n(196)),s(n(541),t),t.hooks=i},541:function(e,t){"use strict";function n(e,t,n){return(t=function(e){return e=function(e,t){if("object"!==r(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0===n)return String(e);if("object"!==r(n=n.call(e,"string")))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}(e),"symbol"===r(e)?e:String(e)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function o(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,s,c=[],a=!0,u=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;a=!1}else for(;!(a=(r=i.call(n)).done)&&(c.push(r.value),c.length!==t);a=!0);}catch(e){u=!0,o=e}finally{try{if(!a&&null!=n.return&&(s=n.return(),Object(s)!==s))return}finally{if(u)throw o}}return c}}(e,t)||function(e,t){var n;if(e)return"string"==typeof e?i(e,t):"Map"===(n="Object"===(n=Object.prototype.toString.call(e).slice(8,-1))&&e.constructor?e.constructor.name:n)||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?i(e,t):void 0}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function i(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}Object.defineProperty(t,"__esModule",{value:!0}),t.createSymbol=t.makeUrl=t.isPromise=t._=t.stripSlashes=void 0,t.stripSlashes=function(e){return e.replace(/^(\/+)|(\/+)$/g,"")},t._={each:function(e,n){e&&"function"==typeof e.forEach?e.forEach(n):t._.isObject(e)&&Object.keys(e).forEach((function(t){return n(e[t],t)}))},some:function(e,t){return Object.keys(e).map((function(t){return[e[t],t]})).some((function(e){var n=(e=o(e,2))[0];return e=e[1],t(n,e)}))},every:function(e,t){return Object.keys(e).map((function(t){return[e[t],t]})).every((function(e){var n=(e=o(e,2))[0];return e=e[1],t(n,e)}))},keys:function(e){return Object.keys(e)},values:function(e){return t._.keys(e).map((function(t){return e[t]}))},isMatch:function(e,n){return t._.keys(n).every((function(t){return e[t]===n[t]}))},isEmpty:function(e){return 0===t._.keys(e).length},isObject:function(e){return"object"===r(e)&&!Array.isArray(e)&&null!==e},isObjectOrArray:function(e){return"object"===r(e)&&null!==e},extend:function(e){for(var t=arguments.length,n=new Array(1<t?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return Object.assign.apply(Object,[e].concat(n))},omit:function(e){for(var n=t._.extend({},e),r=arguments.length,o=new Array(1<r?r-1:0),i=1;i<r;i++)o[i-1]=arguments[i];return o.forEach((function(e){return delete n[e]})),n},pick:function(e){for(var t=arguments.length,n=new Array(1<t?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return n.reduce((function(t,n){return void 0!==e[n]&&(t[n]=e[n]),t}),{})},merge:function(e,r){return t._.isObject(e)&&t._.isObject(r)&&Object.keys(r).forEach((function(o){t._.isObject(r[o])?(e[o]||Object.assign(e,n({},o,{})),t._.merge(e[o],r[o])):Object.assign(e,n({},o,r[o]))})),e}},t.isPromise=function(e){return t._.isObject(e)&&"function"==typeof e.then},t.makeUrl=function(e){var n=(i="function"==typeof(i=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{}).get?i.get.bind(i):function(){})("env")||"production",r=i("host")||process.env.HOST_NAME||"localhost",o="development"===n||"test"===n?"http":"https",i=i("port")||process.env.PORT||3030;return n="development"===n||"test"===n?":".concat(i):"",e=e||"","".concat(o,"://").concat(r).concat(n,"/").concat(t.stripSlashes(e))},t.createSymbol=function(e){return"undefined"!=typeof Symbol?Symbol(e):e}},495:function(e,t,n){var r=n(898)("feathers:application"),o=n(575).stripSlashes,i=n(425),s=n(944),c=n(341),a=n(803),u=i.extend({create:null});e.exports={init:function(){Object.assign(this,{version:a,methods:["find","get","create","update","patch","remove"],mixins:[],services:{},providers:[],_setup:!1,settings:{}}),this.configure(c()),this.configure(s())},get:function(e){return this.settings[e]},set:function(e,t){return this.settings[e]=t,this},disable:function(e){return this.settings[e]=!1,this},disabled:function(e){return!this.settings[e]},enable:function(e){return this.settings[e]=!0,this},enabled:function(e){return!!this.settings[e]},configure:function(e){return e.call(this,this),this},service:function(e,t){if(void 0!==t)throw new Error("Registering a new service with `app.service(path, service)` is no longer supported. Use `app.use(path, service)` instead.");return t=o(e)||"/",void 0===(e=this.services[t])&&"function"==typeof this.defaultService?this.use(t,this.defaultService(t)).service(t):e},use:function(e,t){var n=this,i=2<arguments.length&&void 0!==arguments[2]?arguments[2]:{};if("string"!=typeof e)throw new Error("'".concat(e,"' is not a valid service path."));var s,c=o(e)||"/",a="function"==typeof t.service&&t.services,f=this.methods.concat("setup").some((function(e){return"function"==typeof t[e]}));if(a)s=t,Object.keys(s.services).forEach((function(e){return n.use("".concat(c,"/").concat(e),s.service(e))}));else{if(!f)throw new Error("Invalid service object passed for path `".concat(c,"`"));var l=u.isPrototypeOf(t)?t:u.extend(t);r("Registering new service at `".concat(c,"`")),this.mixins.forEach((function(e){return e.call(n,l,c,i)})),"function"==typeof l._setup&&l._setup(this,c),this.providers.forEach((function(e){return e.call(n,l,c,i)})),this._isSetup&&"function"==typeof l.setup&&(r("Setting up service for `".concat(c,"`")),l.setup(this,c)),this.services[c]=l}return this},setup:function(){var e=this;return Object.keys(this.services).forEach((function(t){var n=e.services[t];r("Setting up service for `".concat(t,"`")),"function"==typeof n.setup&&n.setup(e,t)})),this._isSetup=!0,this}}},944:function(e,t,n){var r=n(699).EventEmitter,o=n(425),i=t.eventHook=function(){return function(e){var t=e.app,n=e.service,r=null===e.event?e.event:t.eventMappings[e.method];t=n._hookEvents&&-1!==n._hookEvents.indexOf(r),r&&t&&"error"!==e.type&&(Array.isArray(e.result)?e.result:[e.result]).forEach((function(t){return n.emit(r,t,e)}))}},s=t.eventMixin=function(e){var t,n;e._serviceEvents||(t=this,n="function"==typeof e.on&&"function"==typeof e.emit,"function"!=typeof e.mixin||n||e.mixin(r.prototype),Object.defineProperties(e,{_serviceEvents:{value:Array.isArray(e.events)?e.events.slice():[]},_hookEvents:{value:[]}}),Object.keys(t.eventMappings).forEach((function(n){var r=t.eventMappings[n],o=-1!==e._serviceEvents.indexOf(r);"function"!=typeof e[n]||o||(e._serviceEvents.push(r),e._hookEvents.push(r))})))};e.exports=function(){return function(e){Object.assign(e,{eventMappings:{create:"created",update:"updated",remove:"removed",patch:"patched"}}),e.hooks({finally:i()}),o.mixin(r.prototype,e),e.mixins.push(s)}}},392:function(e,t,n){var r=n(575)._;e.exports=[function(e){var t=e.service,n=e.method,r=t.methods[n];return e.arguments.forEach((function(t,n){e[r[n]]=t})),e.params||(e.params={}),e},function(e){var t=e.service,n=e.method,o=e.path;if((t=t.methods[n]).includes("id")&&void 0===e.id)throw new Error("An id must be provided to the '".concat(o,".").concat(n,"' method"));if(t.includes("data")&&!r.isObjectOrArray(e.data))throw new Error("A data object must be provided to the '".concat(o,".").concat(n,"' method"));return e}]},341:function(e,t,n){function r(e){var t=e.app,n=e.service,r=e.method,o=e.original;return function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},i=t.hookTypes.reduce((function(t,n){var r=e[n]||[];return t[n]=Array.isArray(r)?r:[r],t}),{});return function(){for(var e=arguments.length,u=new Array(e),l=0;l<e;l++)u[l]=arguments[l];var p=!0===u[u.length-1]&&u.pop(),h=a(r,{type:"before",arguments:u,service:n,app:t});return Promise.resolve(h).then((function(e){return f.call(n,c.concat(i.before),e)})).then((function(e){return void 0!==e.result?e:new Promise((function(t){var i=o||n[r],c=n.methods[r].map((function(t){return e[t]}));if(i=i.apply(n,c),!s(i))throw new Error("Service method '".concat(e.method,"' for '").concat(e.path,"' service must return a promise"));t(i)})).then((function(t){return e.result=t,e})).catch((function(t){throw t.hook=e,t}))})).then((function(e){return e=Object.assign({},e,{type:"after"}),f.call(n,i.after,e)})).catch((function(e){return e=Object.assign({},e.hook,{type:"error",original:e.hook,error:e,result:void 0}),f.call(n,i.error,e).catch((function(e){return Object.assign({},e.hook,{error:e,result:void 0})}))})).then((function(e){return f.call(n,i.finally,e).catch((function(e){return Object.assign({},e.hook,{error:e,result:void 0})}))})).then((function(e){return void 0!==e.error&&void 0===e.result?Promise.reject(p?e:e.error):p?e:e.result}))}}}var o=n(575),i=o.hooks,s=o.isPromise,c=n(392),a=i.createHookObject,u=i.getHooks,f=i.processHooks,l=i.enableHooks,p=i.ACTIVATE_HOOKS,h=t.hookMixin=function(e){var t,n,o;"function"!=typeof e.hooks&&(e.methods=Object.getOwnPropertyNames(e).filter((function(t){return"function"==typeof e[t]&&e[t][p]})).reduce((function(t,n){return t[n]=e[n][p],t}),e.methods||{}),Object.assign(e.methods,{find:["params"],get:["id","params"],create:["data","params"],update:["id","data","params"],patch:["id","data","params"],remove:["id","params"]}),t=this,o=(n=Object.keys(e.methods)).reduce((function(n,o){return"function"==typeof e[o]&&(n[o]=function(){var e=this,n=Array.from(arguments),i=e._super.bind(e);return r({app:t,service:e,method:o,original:i})({before:u(t,e,"before",o),after:u(t,e,"after",o,!0),error:u(t,e,"error",o,!0),finally:u(t,e,"finally",o,!0)}).apply(void 0,n)}),n}),{}),l(e,n,t.hookTypes),e.mixin(o))};e.exports=function(){return function(e){Object.assign(e,{hookTypes:["before","after","error","finally"]}),l(e,e.methods,e.hookTypes),e.mixins.push(h)}},e.exports.withHooks=r,e.exports.ACTIVATE_HOOKS=p,e.exports.activateHooks=function(e){return function(t){return Object.defineProperty(t,p,{value:e}),t}}},845:function(e,t,n){var r=n(425),o=n(495),i=n(803),s=(n=n(341)).ACTIVATE_HOOKS,c=(n=n.activateHooks,Object.create(null));function a(){var e=Object.create(c);return r.mixin(o,e),e.init(),e}a.version=i,a.ACTIVATE_HOOKS=s,a.activateHooks=n,e.exports=a,e.exports.default=a},803:function(e){e.exports="4.5.16"},699:function(e){"use strict";var t="object"==typeof Reflect?Reflect:null,n=t&&"function"==typeof t.apply?t.apply:function(e,t,n){return Function.prototype.apply.call(e,t,n)},r=t&&"function"==typeof t.ownKeys?t.ownKeys:Object.getOwnPropertySymbols?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:function(e){return Object.getOwnPropertyNames(e)},o=Number.isNaN||function(e){return e!=e};function i(){i.init.call(this)}e.exports=i,e.exports.once=function(e,t){return new Promise((function(n,r){function o(n){e.removeListener(t,i),r(n)}function i(){"function"==typeof e.removeListener&&e.removeListener("error",o),n([].slice.call(arguments))}var s,c,a;v(e,t,i,{once:!0}),"error"!==t&&(c=o,a={once:!0},"function"==typeof(s=e).on)&&v(s,"error",c,a)}))},(i.EventEmitter=i).prototype._events=void 0,i.prototype._eventsCount=0,i.prototype._maxListeners=void 0;var s=10;function c(e){if("function"!=typeof e)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof e)}function a(e){return void 0===e._maxListeners?i.defaultMaxListeners:e._maxListeners}function u(e,t,n,r){var o,i;return c(n),void 0===(o=e._events)?(o=e._events=Object.create(null),e._eventsCount=0):(void 0!==o.newListener&&(e.emit("newListener",t,n.listener||n),o=e._events),i=o[t]),void 0===i?(i=o[t]=n,++e._eventsCount):("function"==typeof i?i=o[t]=r?[n,i]:[i,n]:r?i.unshift(n):i.push(n),0<(o=a(e))&&i.length>o&&!i.warned&&(i.warned=!0,(r=new Error("Possible EventEmitter memory leak detected. "+i.length+" "+String(t)+" listeners added. Use emitter.setMaxListeners() to increase limit")).name="MaxListenersExceededWarning",r.emitter=e,r.type=t,r.count=i.length,n=r,console)&&console.warn&&console.warn(n)),e}function f(e,t,n){return t=function(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,0===arguments.length?this.listener.call(this.target):this.listener.apply(this.target,arguments)}.bind(e={fired:!1,wrapFn:void 0,target:e,type:t,listener:n}),t.listener=n,e.wrapFn=t}function l(e,t,n){if(void 0===(e=e._events))return[];if(void 0===(e=e[t]))return[];if("function"==typeof e)return n?[e.listener||e]:[e];if(n){for(var r=e,o=new Array(r.length),i=0;i<o.length;++i)o[i]=r[i].listener||r[i];return o}return h(e,e.length)}function p(e){var t=this._events;if(void 0!==t){if("function"==typeof(t=t[e]))return 1;if(void 0!==t)return t.length}return 0}function h(e,t){for(var n=new Array(t),r=0;r<t;++r)n[r]=e[r];return n}function v(e,t,n,r){if("function"==typeof e.on)r.once?e.once(t,n):e.on(t,n);else{if("function"!=typeof e.addEventListener)throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type '+typeof e);e.addEventListener(t,(function o(i){r.once&&e.removeEventListener(t,o),n(i)}))}}Object.defineProperty(i,"defaultMaxListeners",{enumerable:!0,get:function(){return s},set:function(e){if("number"!=typeof e||e<0||o(e))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+e+".");s=e}}),i.init=function(){void 0!==this._events&&this._events!==Object.getPrototypeOf(this)._events||(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},i.prototype.setMaxListeners=function(e){if("number"!=typeof e||e<0||o(e))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+e+".");return this._maxListeners=e,this},i.prototype.getMaxListeners=function(){return a(this)},i.prototype.emit=function(e){for(var t=[],r=1;r<arguments.length;r++)t.push(arguments[r]);var o="error"===e,i=this._events;if(void 0!==i)o=o&&void 0===i.error;else if(!o)return!1;if(o){if((s=0<t.length?t[0]:s)instanceof Error)throw s;throw(o=new Error("Unhandled error."+(s?" ("+s.message+")":""))).context=s,o}var s=i[e];if(void 0===s)return!1;if("function"==typeof s)n(s,this,t);else{var c=s.length,a=h(s,c);for(r=0;r<c;++r)n(a[r],this,t)}return!0},i.prototype.on=i.prototype.addListener=function(e,t){return u(this,e,t,!1)},i.prototype.prependListener=function(e,t){return u(this,e,t,!0)},i.prototype.once=function(e,t){return c(t),this.on(e,f(this,e,t)),this},i.prototype.prependOnceListener=function(e,t){return c(t),this.prependListener(e,f(this,e,t)),this},i.prototype.off=i.prototype.removeListener=function(e,t){var n,r,o,i,s;if(c(t),void 0!==(r=this._events)&&void 0!==(n=r[e]))if(n===t||n.listener===t)0==--this._eventsCount?this._events=Object.create(null):(delete r[e],r.removeListener&&this.emit("removeListener",e,n.listener||t));else if("function"!=typeof n){for(o=-1,i=n.length-1;0<=i;i--)if(n[i]===t||n[i].listener===t){s=n[i].listener,o=i;break}if(o<0)return this;if(0===o)n.shift();else{for(var a=n,u=o;u+1<a.length;u++)a[u]=a[u+1];a.pop()}1===n.length&&(r[e]=n[0]),void 0!==r.removeListener&&this.emit("removeListener",e,s||t)}return this},i.prototype.removeAllListeners=function(e){var t,n=this._events;if(void 0!==n)if(void 0===n.removeListener)0===arguments.length?(this._events=Object.create(null),this._eventsCount=0):void 0!==n[e]&&(0==--this._eventsCount?this._events=Object.create(null):delete n[e]);else if(0===arguments.length){for(var r,o=Object.keys(n),i=0;i<o.length;++i)"removeListener"!==(r=o[i])&&this.removeAllListeners(r);this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0}else if("function"==typeof(t=n[e]))this.removeListener(e,t);else if(void 0!==t)for(i=t.length-1;0<=i;i--)this.removeListener(e,t[i]);return this},i.prototype.listeners=function(e){return l(this,e,!0)},i.prototype.rawListeners=function(e){return l(this,e,!1)},i.listenerCount=function(e,t){return"function"==typeof e.listenerCount?e.listenerCount(t):p.call(e,t)},i.prototype.listenerCount=p,i.prototype.eventNames=function(){return 0<this._eventsCount?r(this._events):[]}},378:function(e){var t=36e5,n=864e5;function r(e,t,n,r){return t=1.5*n<=t,Math.round(e/n)+" "+r+(t?"s":"")}e.exports=function(e,o){o=o||{};var i=typeof e;if(!("string"==i&&0<e.length)){if("number"==i&&isFinite(e))return(o.long?function(e){var o=Math.abs(e);return n<=o?r(e,o,n,"day"):t<=o?r(e,o,t,"hour"):6e4<=o?r(e,o,6e4,"minute"):1e3<=o?r(e,o,1e3,"second"):e+" ms"}:function(e){var r=Math.abs(e);return n<=r?Math.round(e/n)+"d":t<=r?Math.round(e/t)+"h":6e4<=r?Math.round(e/6e4)+"m":1e3<=r?Math.round(e/1e3)+"s":e+"ms"})(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}if(i=e,!(100<(i=String(i)).length)&&(i=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(i))){var s=parseFloat(i[1]);switch((i[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return 315576e5*s;case"weeks":case"week":case"w":return 6048e5*s;case"days":case"day":case"d":return s*n;case"hours":case"hour":case"hrs":case"hr":case"h":return s*t;case"minutes":case"minute":case"mins":case"min":case"m":return 6e4*s;case"seconds":case"second":case"secs":case"sec":case"s":return 1e3*s;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return s;default:return}}}},425:function(e,t){var n;void 0!==(t="function"==typeof(n=function(){var e="function"==typeof Object.getOwnPropertySymbols;return{create:function(){var e=Object.create(this),t="string"==typeof e.__init?e.__init:"init";return"function"==typeof e[t]&&e[t].apply(e,arguments),e},mixin:function(t,n){var r=n||this,o=/\b_super\b/,i=Object.getPrototypeOf(r)||r.prototype,s={},c=t,a=function(e){var t=Object.getOwnPropertyDescriptor(c,e);!s[e]&&t&&(s[e]=t)};do{Object.getOwnPropertyNames(c).forEach(a),e&&Object.getOwnPropertySymbols(c).forEach(a)}while((c=Object.getPrototypeOf(c))&&Object.getPrototypeOf(c));var u=function(t){var n=s[t];"function"==typeof n.value&&o.test(n.value)&&(n.value=function(t,n,r,o){var i="function"==typeof n,s=function(){var e=this._super;this._super=i?n:t[r];var s=o.apply(this,arguments);return this._super=e,s};return i&&(Object.keys(n).forEach((function(e){s[e]=n[e]})),e&&Object.getOwnPropertySymbols(n).forEach((function(e){s[e]=n[e]}))),s}(i,r[t],t,n.value)),Object.defineProperty(r,t,n)};return Object.keys(s).forEach(u),e&&Object.getOwnPropertySymbols(s).forEach(u),r},extend:function(e,t){return this.mixin(e,Object.create(t||this))},proxy:function(e){var t=this[e],n=Array.prototype.slice.call(arguments,1);return n.unshift(this),t.bind.apply(t,n)}}})?n.apply(t,[]):n)&&(e.exports=t)}},t={},function n(r){var o=t[r];return void 0===o&&(o=t[r]={exports:{}},e[r].call(o.exports,o,o.exports,n)),o.exports}(630);var e,t}));
1
+ !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.feathers=t():e.feathers=t()}(this,(function(){return e={898:function(e,t,n){var r;t.formatArgs=function(t){var n,r,o;t[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+t[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff),this.useColors&&(n="color: "+this.color,t.splice(1,0,n,"color: inherit"),t[o=r=0].replace(/%[a-zA-Z%]/g,(function(e){"%%"!==e&&(r++,"%c"===e)&&(o=r)})),t.splice(o,0,n))},t.save=function(e){try{e?t.storage.setItem("debug",e):t.storage.removeItem("debug")}catch(e){}},t.load=function(){var e;try{e=t.storage.getItem("debug")}catch(e){}return!e&&"undefined"!=typeof process&&"env"in process&&(e=process.env.DEBUG),e},t.useColors=function(){return!("undefined"==typeof window||!window.process||"renderer"!==window.process.type&&!window.process.__nwjs)||("undefined"==typeof navigator||!navigator.userAgent||!navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))&&("undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&31<=parseInt(RegExp.$1,10)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))},t.storage=function(){try{return localStorage}catch(e){}}(),t.destroy=(r=!1,function(){r||(r=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."))}),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],t.log=console.debug||console.log||function(){},e.exports=n(604)(t),e.exports.formatters.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}},604:function(e,t,n){function r(e){return function(e){if(Array.isArray(e))return o(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){var n;if(e)return"string"==typeof e?o(e,t):"Map"===(n="Object"===(n=Object.prototype.toString.call(e).slice(8,-1))&&e.constructor?e.constructor.name:n)||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?o(e,t):void 0}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function o(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}e.exports=function(e){function t(e){var n,r,i,s=null;function c(){for(var e,r,o,i,s=arguments.length,a=new Array(s),u=0;u<s;u++)a[u]=arguments[u];c.enabled&&(e=c,o=(r=Number(new Date))-(n||r),e.diff=o,e.prev=n,e.curr=r,n=r,a[0]=t.coerce(a[0]),"string"!=typeof a[0]&&a.unshift("%O"),a[i=0]=a[0].replace(/%([a-zA-Z%])/g,(function(n,r){return"%%"===n?"%":(i++,"function"==typeof(r=t.formatters[r])&&(o=a[i],n=r.call(e,o),a.splice(i,1),i--),n);var o})),t.formatArgs.call(e,a),(e.log||t.log).apply(e,a))}return c.namespace=e,c.useColors=t.useColors(),c.color=t.selectColor(e),c.extend=o,c.destroy=t.destroy,Object.defineProperty(c,"enabled",{enumerable:!0,configurable:!1,get:function(){return null!==s?s:(r!==t.namespaces&&(r=t.namespaces,i=t.enabled(e)),i)},set:function(e){s=e}}),"function"==typeof t.init&&t.init(c),c}function o(e,n){return(n=t(this.namespace+(void 0===n?":":n)+e)).log=this.log,n}function i(e){return e.toString().substring(2,e.toString().length-2).replace(/\.\*\?$/,"*")}return((t.debug=t).default=t).coerce=function(e){return e instanceof Error?e.stack||e.message:e},t.disable=function(){var e=[].concat(r(t.names.map(i)),r(t.skips.map(i).map((function(e){return"-"+e})))).join(",");return t.enable(""),e},t.enable=function(e){t.save(e),t.namespaces=e,t.names=[],t.skips=[];var n,r=("string"==typeof e?e:"").split(/[\s,]+/),o=r.length;for(n=0;n<o;n++)r[n]&&("-"===(e=r[n].replace(/\*/g,".*?"))[0]?t.skips.push(new RegExp("^"+e.slice(1)+"$")):t.names.push(new RegExp("^"+e+"$")))},t.enabled=function(e){if("*"===e[e.length-1])return!0;var n,r;for(n=0,r=t.skips.length;n<r;n++)if(t.skips[n].test(e))return!1;for(n=0,r=t.names.length;n<r;n++)if(t.names[n].test(e))return!0;return!1},t.humanize=n(378),t.destroy=function(){console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")},Object.keys(e).forEach((function(n){t[n]=e[n]})),t.names=[],t.skips=[],t.formatters={},t.selectColor=function(e){for(var n=0,r=0;r<e.length;r++)n=(n<<5)-n+e.charCodeAt(r),n|=0;return t.colors[Math.abs(n)%t.colors.length]},t.enable(t.load()),t}},630:function(e,t,n){e.exports=n(845)},196:function(e,t,n){"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.enableHooks=t.processHooks=t.getHooks=t.isHookObject=t.convertHookData=t.makeArguments=t.defaultMakeArguments=t.createHookObject=t.ACTIVATE_HOOKS=void 0;var o=(n=n(541))._,i=o.each,s=o.pick;function c(e){var t=[];return void 0!==e.id&&t.push(e.id),e.data&&t.push(e.data),t.push(e.params||{}),t}function a(e){var t={};return Array.isArray(e)?t={all:e}:"object"!==r(e)?t={all:[e]}:i(e,(function(e,n){t[n]=Array.isArray(e)?e:[e]})),t}function u(e){return"object"===r(e)&&"string"==typeof e.method&&"string"==typeof e.type}t.ACTIVATE_HOOKS=(0,n.createSymbol)("__feathersActivateHooks"),t.createHookObject=function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},n={};return Object.defineProperty(n,"toJSON",{value:function(){return s(this,"type","method","path","params","id","data","result","error")}}),Object.assign(n,t,{method:e,get path(){var e=t.app,n=t.service;return n&&e&&e.services?Object.keys(e.services).find((function(t){return e.services[t]===n})):null}})},t.defaultMakeArguments=c,t.makeArguments=function(e){switch(e.method){case"find":return[e.params];case"get":case"remove":return[e.id,e.params];case"update":case"patch":return[e.id,e.data,e.params];case"create":return[e.data,e.params]}return c(e)},t.convertHookData=a,t.isHookObject=u,t.getHooks=function(e,t,n,r){return e=e.__hooks[n][r]||[],t=t.__hooks[n][r]||[],4<arguments.length&&void 0!==arguments[4]&&arguments[4]?t.concat(e):e.concat(t)},t.processHooks=function(e,t){function n(e){if(e){if(!u(e))throw new Error("".concat(o.type," hook for '").concat(o.method,"' method returned invalid hook object"));o=e}return o}var r=this,o=t;return e.reduce((function(e,t){var o=t.bind(r);return e.then((function(e){return o(e)})).then(n)}),Promise.resolve(o)).then((function(){return o})).catch((function(e){throw e.hook=o,e}))},t.enableHooks=function(e,t,n){var r;return"function"==typeof e.hooks?e:(r={},n.forEach((function(e){r[e]={}})),Object.defineProperty(e,"__hooks",{configurable:!0,value:r,writable:!0}),Object.assign(e,{hooks:function(e){var n=this;return i(e,(function(e,r){if(!n.__hooks[r])throw new Error("'".concat(r,"' is not a valid hook type"));var o=a(e);i(o,(function(e,n){if("all"!==n&&-1===t.indexOf(n))throw new Error("'".concat(n,"' is not a valid hook method"))})),t.forEach((function(e){var t=n.__hooks[r][e]||(n.__hooks[r][e]=[]);o.all&&t.push.apply(t,o.all),o[e]&&t.push.apply(t,o[e])}))})),this}}))}},575:function(e,t,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n);var o=Object.getOwnPropertyDescriptor(t,n);o&&("get"in o?t.__esModule:!o.writable&&!o.configurable)||(o={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,o)}:function(e,t,n,r){e[r=void 0===r?n:r]=t[n]}),o=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),i=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)"default"!==n&&Object.prototype.hasOwnProperty.call(e,n)&&r(t,e,n);return o(t,e),t},s=this&&this.__exportStar||function(e,t){for(var n in e)"default"===n||Object.prototype.hasOwnProperty.call(t,n)||r(t,e,n)};Object.defineProperty(t,"__esModule",{value:!0}),t.hooks=void 0,i=i(n(196)),s(n(541),t),t.hooks=i},541:function(e,t){"use strict";function n(e,t,n){return(t=function(e){return e=function(e,t){if("object"!==r(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0===n)return String(e);if("object"!==r(n=n.call(e,"string")))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}(e),"symbol"===r(e)?e:String(e)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function o(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,s,c=[],a=!0,u=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;a=!1}else for(;!(a=(r=i.call(n)).done)&&(c.push(r.value),c.length!==t);a=!0);}catch(e){u=!0,o=e}finally{try{if(!a&&null!=n.return&&(s=n.return(),Object(s)!==s))return}finally{if(u)throw o}}return c}}(e,t)||function(e,t){var n;if(e)return"string"==typeof e?i(e,t):"Map"===(n="Object"===(n=Object.prototype.toString.call(e).slice(8,-1))&&e.constructor?e.constructor.name:n)||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?i(e,t):void 0}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function i(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}Object.defineProperty(t,"__esModule",{value:!0}),t.createSymbol=t.makeUrl=t.isPromise=t._=t.stripSlashes=void 0,t.stripSlashes=function(e){return e.replace(/^(\/+)|(\/+)$/g,"")},t._={each:function(e,n){e&&"function"==typeof e.forEach?e.forEach(n):t._.isObject(e)&&Object.keys(e).forEach((function(t){return n(e[t],t)}))},some:function(e,t){return Object.keys(e).map((function(t){return[e[t],t]})).some((function(e){var n=(e=o(e,2))[0];return e=e[1],t(n,e)}))},every:function(e,t){return Object.keys(e).map((function(t){return[e[t],t]})).every((function(e){var n=(e=o(e,2))[0];return e=e[1],t(n,e)}))},keys:function(e){return Object.keys(e)},values:function(e){return t._.keys(e).map((function(t){return e[t]}))},isMatch:function(e,n){return t._.keys(n).every((function(t){return e[t]===n[t]}))},isEmpty:function(e){return 0===t._.keys(e).length},isObject:function(e){return"object"===r(e)&&!Array.isArray(e)&&null!==e},isObjectOrArray:function(e){return"object"===r(e)&&null!==e},extend:function(e){for(var t=arguments.length,n=new Array(1<t?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return Object.assign.apply(Object,[e].concat(n))},omit:function(e){for(var n=t._.extend({},e),r=arguments.length,o=new Array(1<r?r-1:0),i=1;i<r;i++)o[i-1]=arguments[i];return o.forEach((function(e){return delete n[e]})),n},pick:function(e){for(var t=arguments.length,n=new Array(1<t?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return n.reduce((function(t,n){return void 0!==e[n]&&(t[n]=e[n]),t}),{})},merge:function(e,r){return t._.isObject(e)&&t._.isObject(r)&&Object.keys(r).forEach((function(o){t._.isObject(r[o])?(e[o]||Object.assign(e,n({},o,{})),t._.merge(e[o],r[o])):Object.assign(e,n({},o,r[o]))})),e}},t.isPromise=function(e){return t._.isObject(e)&&"function"==typeof e.then},t.makeUrl=function(e){var n=(i="function"==typeof(i=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{}).get?i.get.bind(i):function(){})("env")||"production",r=i("host")||process.env.HOST_NAME||"localhost",o="development"===n||"test"===n?"http":"https",i=i("port")||process.env.PORT||3030;return n="development"===n||"test"===n?":".concat(i):"",e=e||"","".concat(o,"://").concat(r).concat(n,"/").concat(t.stripSlashes(e))},t.createSymbol=function(e){return"undefined"!=typeof Symbol?Symbol(e):e}},495:function(e,t,n){var r=n(898)("feathers:application"),o=n(575).stripSlashes,i=n(425),s=n(944),c=n(341),a=n(803),u=i.extend({create:null});e.exports={init:function(){Object.assign(this,{version:a,methods:["find","get","create","update","patch","remove"],mixins:[],services:{},providers:[],_setup:!1,settings:{}}),this.configure(c()),this.configure(s())},get:function(e){return this.settings[e]},set:function(e,t){return this.settings[e]=t,this},disable:function(e){return this.settings[e]=!1,this},disabled:function(e){return!this.settings[e]},enable:function(e){return this.settings[e]=!0,this},enabled:function(e){return!!this.settings[e]},configure:function(e){return e.call(this,this),this},service:function(e,t){if(void 0!==t)throw new Error("Registering a new service with `app.service(path, service)` is no longer supported. Use `app.use(path, service)` instead.");return t=o(e)||"/",void 0===(e=this.services.hasOwnProperty(t)?this.services[t]:void 0)&&"function"==typeof this.defaultService?this.use(t,this.defaultService(t)).service(t):e},use:function(e,t){var n=this,i=2<arguments.length&&void 0!==arguments[2]?arguments[2]:{};if("string"!=typeof e)throw new Error("'".concat(e,"' is not a valid service path."));var s,c=o(e)||"/",a="function"==typeof t.service&&t.services,f=this.methods.concat("setup").some((function(e){return"function"==typeof t[e]}));if(a)s=t,Object.keys(s.services).forEach((function(e){return n.use("".concat(c,"/").concat(e),s.service(e))}));else{if(!f)throw new Error("Invalid service object passed for path `".concat(c,"`"));var l=u.isPrototypeOf(t)?t:u.extend(t);r("Registering new service at `".concat(c,"`")),this.mixins.forEach((function(e){return e.call(n,l,c,i)})),"function"==typeof l._setup&&l._setup(this,c),this.providers.forEach((function(e){return e.call(n,l,c,i)})),this._isSetup&&"function"==typeof l.setup&&(r("Setting up service for `".concat(c,"`")),l.setup(this,c)),this.services[c]=l}return this},setup:function(){var e=this;return Object.keys(this.services).forEach((function(t){var n=e.services[t];r("Setting up service for `".concat(t,"`")),"function"==typeof n.setup&&n.setup(e,t)})),this._isSetup=!0,this}}},944:function(e,t,n){var r=n(699).EventEmitter,o=n(425),i=t.eventHook=function(){return function(e){var t=e.app,n=e.service,r=null===e.event?e.event:t.eventMappings[e.method];t=n._hookEvents&&-1!==n._hookEvents.indexOf(r),r&&t&&"error"!==e.type&&(Array.isArray(e.result)?e.result:[e.result]).forEach((function(t){return n.emit(r,t,e)}))}},s=t.eventMixin=function(e){var t,n;e._serviceEvents||(t=this,n="function"==typeof e.on&&"function"==typeof e.emit,"function"!=typeof e.mixin||n||e.mixin(r.prototype),Object.defineProperties(e,{_serviceEvents:{value:Array.isArray(e.events)?e.events.slice():[]},_hookEvents:{value:[]}}),Object.keys(t.eventMappings).forEach((function(n){var r=t.eventMappings[n],o=-1!==e._serviceEvents.indexOf(r);"function"!=typeof e[n]||o||(e._serviceEvents.push(r),e._hookEvents.push(r))})))};e.exports=function(){return function(e){Object.assign(e,{eventMappings:{create:"created",update:"updated",remove:"removed",patch:"patched"}}),e.hooks({finally:i()}),o.mixin(r.prototype,e),e.mixins.push(s)}}},392:function(e,t,n){var r=n(575)._;e.exports=[function(e){var t=e.service,n=e.method,r=t.methods[n];return e.arguments.forEach((function(t,n){e[r[n]]=t})),e.params||(e.params={}),e},function(e){var t=e.service,n=e.method,o=e.path;if((t=t.methods[n]).includes("id")&&void 0===e.id)throw new Error("An id must be provided to the '".concat(o,".").concat(n,"' method"));if(t.includes("data")&&!r.isObjectOrArray(e.data))throw new Error("A data object must be provided to the '".concat(o,".").concat(n,"' method"));return e}]},341:function(e,t,n){function r(e){var t=e.app,n=e.service,r=e.method,o=e.original;return function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},i=t.hookTypes.reduce((function(t,n){var r=e[n]||[];return t[n]=Array.isArray(r)?r:[r],t}),{});return function(){for(var e=arguments.length,u=new Array(e),l=0;l<e;l++)u[l]=arguments[l];var p=!0===u[u.length-1]&&u.pop(),h=a(r,{type:"before",arguments:u,service:n,app:t});return Promise.resolve(h).then((function(e){return f.call(n,c.concat(i.before),e)})).then((function(e){return void 0!==e.result?e:new Promise((function(t){var i=o||n[r],c=n.methods[r].map((function(t){return e[t]}));if(i=i.apply(n,c),!s(i))throw new Error("Service method '".concat(e.method,"' for '").concat(e.path,"' service must return a promise"));t(i)})).then((function(t){return e.result=t,e})).catch((function(t){throw t.hook=e,t}))})).then((function(e){return e=Object.assign({},e,{type:"after"}),f.call(n,i.after,e)})).catch((function(e){return e=Object.assign({},e.hook,{type:"error",original:e.hook,error:e,result:void 0}),f.call(n,i.error,e).catch((function(e){return Object.assign({},e.hook,{error:e,result:void 0})}))})).then((function(e){return f.call(n,i.finally,e).catch((function(e){return Object.assign({},e.hook,{error:e,result:void 0})}))})).then((function(e){return void 0!==e.error&&void 0===e.result?Promise.reject(p?e:e.error):p?e:e.result}))}}}var o=n(575),i=o.hooks,s=o.isPromise,c=n(392),a=i.createHookObject,u=i.getHooks,f=i.processHooks,l=i.enableHooks,p=i.ACTIVATE_HOOKS,h=t.hookMixin=function(e){var t,n,o;"function"!=typeof e.hooks&&(e.methods=Object.getOwnPropertyNames(e).filter((function(t){return"function"==typeof e[t]&&e[t][p]})).reduce((function(t,n){return t[n]=e[n][p],t}),e.methods||{}),Object.assign(e.methods,{find:["params"],get:["id","params"],create:["data","params"],update:["id","data","params"],patch:["id","data","params"],remove:["id","params"]}),t=this,o=(n=Object.keys(e.methods)).reduce((function(n,o){return"function"==typeof e[o]&&(n[o]=function(){var e=this,n=Array.from(arguments),i=e._super.bind(e);return r({app:t,service:e,method:o,original:i})({before:u(t,e,"before",o),after:u(t,e,"after",o,!0),error:u(t,e,"error",o,!0),finally:u(t,e,"finally",o,!0)}).apply(void 0,n)}),n}),{}),l(e,n,t.hookTypes),e.mixin(o))};e.exports=function(){return function(e){Object.assign(e,{hookTypes:["before","after","error","finally"]}),l(e,e.methods,e.hookTypes),e.mixins.push(h)}},e.exports.withHooks=r,e.exports.ACTIVATE_HOOKS=p,e.exports.activateHooks=function(e){return function(t){return Object.defineProperty(t,p,{value:e}),t}}},845:function(e,t,n){var r=n(425),o=n(495),i=n(803),s=(n=n(341)).ACTIVATE_HOOKS,c=(n=n.activateHooks,Object.create(null));function a(){var e=Object.create(c);return r.mixin(o,e),e.init(),e}a.version=i,a.ACTIVATE_HOOKS=s,a.activateHooks=n,e.exports=a,e.exports.default=a},803:function(e){e.exports="development"},699:function(e){"use strict";var t="object"==typeof Reflect?Reflect:null,n=t&&"function"==typeof t.apply?t.apply:function(e,t,n){return Function.prototype.apply.call(e,t,n)},r=t&&"function"==typeof t.ownKeys?t.ownKeys:Object.getOwnPropertySymbols?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:function(e){return Object.getOwnPropertyNames(e)},o=Number.isNaN||function(e){return e!=e};function i(){i.init.call(this)}e.exports=i,e.exports.once=function(e,t){return new Promise((function(n,r){function o(n){e.removeListener(t,i),r(n)}function i(){"function"==typeof e.removeListener&&e.removeListener("error",o),n([].slice.call(arguments))}var s,c,a;v(e,t,i,{once:!0}),"error"!==t&&(c=o,a={once:!0},"function"==typeof(s=e).on)&&v(s,"error",c,a)}))},(i.EventEmitter=i).prototype._events=void 0,i.prototype._eventsCount=0,i.prototype._maxListeners=void 0;var s=10;function c(e){if("function"!=typeof e)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof e)}function a(e){return void 0===e._maxListeners?i.defaultMaxListeners:e._maxListeners}function u(e,t,n,r){var o,i;return c(n),void 0===(o=e._events)?(o=e._events=Object.create(null),e._eventsCount=0):(void 0!==o.newListener&&(e.emit("newListener",t,n.listener||n),o=e._events),i=o[t]),void 0===i?(i=o[t]=n,++e._eventsCount):("function"==typeof i?i=o[t]=r?[n,i]:[i,n]:r?i.unshift(n):i.push(n),0<(o=a(e))&&i.length>o&&!i.warned&&(i.warned=!0,(r=new Error("Possible EventEmitter memory leak detected. "+i.length+" "+String(t)+" listeners added. Use emitter.setMaxListeners() to increase limit")).name="MaxListenersExceededWarning",r.emitter=e,r.type=t,r.count=i.length,n=r,console)&&console.warn&&console.warn(n)),e}function f(e,t,n){return t=function(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,0===arguments.length?this.listener.call(this.target):this.listener.apply(this.target,arguments)}.bind(e={fired:!1,wrapFn:void 0,target:e,type:t,listener:n}),t.listener=n,e.wrapFn=t}function l(e,t,n){if(void 0===(e=e._events))return[];if(void 0===(e=e[t]))return[];if("function"==typeof e)return n?[e.listener||e]:[e];if(n){for(var r=e,o=new Array(r.length),i=0;i<o.length;++i)o[i]=r[i].listener||r[i];return o}return h(e,e.length)}function p(e){var t=this._events;if(void 0!==t){if("function"==typeof(t=t[e]))return 1;if(void 0!==t)return t.length}return 0}function h(e,t){for(var n=new Array(t),r=0;r<t;++r)n[r]=e[r];return n}function v(e,t,n,r){if("function"==typeof e.on)r.once?e.once(t,n):e.on(t,n);else{if("function"!=typeof e.addEventListener)throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type '+typeof e);e.addEventListener(t,(function o(i){r.once&&e.removeEventListener(t,o),n(i)}))}}Object.defineProperty(i,"defaultMaxListeners",{enumerable:!0,get:function(){return s},set:function(e){if("number"!=typeof e||e<0||o(e))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+e+".");s=e}}),i.init=function(){void 0!==this._events&&this._events!==Object.getPrototypeOf(this)._events||(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},i.prototype.setMaxListeners=function(e){if("number"!=typeof e||e<0||o(e))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+e+".");return this._maxListeners=e,this},i.prototype.getMaxListeners=function(){return a(this)},i.prototype.emit=function(e){for(var t=[],r=1;r<arguments.length;r++)t.push(arguments[r]);var o="error"===e,i=this._events;if(void 0!==i)o=o&&void 0===i.error;else if(!o)return!1;if(o){if((s=0<t.length?t[0]:s)instanceof Error)throw s;throw(o=new Error("Unhandled error."+(s?" ("+s.message+")":""))).context=s,o}var s=i[e];if(void 0===s)return!1;if("function"==typeof s)n(s,this,t);else{var c=s.length,a=h(s,c);for(r=0;r<c;++r)n(a[r],this,t)}return!0},i.prototype.on=i.prototype.addListener=function(e,t){return u(this,e,t,!1)},i.prototype.prependListener=function(e,t){return u(this,e,t,!0)},i.prototype.once=function(e,t){return c(t),this.on(e,f(this,e,t)),this},i.prototype.prependOnceListener=function(e,t){return c(t),this.prependListener(e,f(this,e,t)),this},i.prototype.off=i.prototype.removeListener=function(e,t){var n,r,o,i,s;if(c(t),void 0!==(r=this._events)&&void 0!==(n=r[e]))if(n===t||n.listener===t)0==--this._eventsCount?this._events=Object.create(null):(delete r[e],r.removeListener&&this.emit("removeListener",e,n.listener||t));else if("function"!=typeof n){for(o=-1,i=n.length-1;0<=i;i--)if(n[i]===t||n[i].listener===t){s=n[i].listener,o=i;break}if(o<0)return this;if(0===o)n.shift();else{for(var a=n,u=o;u+1<a.length;u++)a[u]=a[u+1];a.pop()}1===n.length&&(r[e]=n[0]),void 0!==r.removeListener&&this.emit("removeListener",e,s||t)}return this},i.prototype.removeAllListeners=function(e){var t,n=this._events;if(void 0!==n)if(void 0===n.removeListener)0===arguments.length?(this._events=Object.create(null),this._eventsCount=0):void 0!==n[e]&&(0==--this._eventsCount?this._events=Object.create(null):delete n[e]);else if(0===arguments.length){for(var r,o=Object.keys(n),i=0;i<o.length;++i)"removeListener"!==(r=o[i])&&this.removeAllListeners(r);this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0}else if("function"==typeof(t=n[e]))this.removeListener(e,t);else if(void 0!==t)for(i=t.length-1;0<=i;i--)this.removeListener(e,t[i]);return this},i.prototype.listeners=function(e){return l(this,e,!0)},i.prototype.rawListeners=function(e){return l(this,e,!1)},i.listenerCount=function(e,t){return"function"==typeof e.listenerCount?e.listenerCount(t):p.call(e,t)},i.prototype.listenerCount=p,i.prototype.eventNames=function(){return 0<this._eventsCount?r(this._events):[]}},378:function(e){var t=36e5,n=864e5;function r(e,t,n,r){return t=1.5*n<=t,Math.round(e/n)+" "+r+(t?"s":"")}e.exports=function(e,o){o=o||{};var i=typeof e;if(!("string"==i&&0<e.length)){if("number"==i&&isFinite(e))return(o.long?function(e){var o=Math.abs(e);return n<=o?r(e,o,n,"day"):t<=o?r(e,o,t,"hour"):6e4<=o?r(e,o,6e4,"minute"):1e3<=o?r(e,o,1e3,"second"):e+" ms"}:function(e){var r=Math.abs(e);return n<=r?Math.round(e/n)+"d":t<=r?Math.round(e/t)+"h":6e4<=r?Math.round(e/6e4)+"m":1e3<=r?Math.round(e/1e3)+"s":e+"ms"})(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}if(i=e,!(100<(i=String(i)).length)&&(i=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(i))){var s=parseFloat(i[1]);switch((i[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return 315576e5*s;case"weeks":case"week":case"w":return 6048e5*s;case"days":case"day":case"d":return s*n;case"hours":case"hour":case"hrs":case"hr":case"h":return s*t;case"minutes":case"minute":case"mins":case"min":case"m":return 6e4*s;case"seconds":case"second":case"secs":case"sec":case"s":return 1e3*s;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return s;default:return}}}},425:function(e,t){var n;void 0!==(t="function"==typeof(n=function(){var e="function"==typeof Object.getOwnPropertySymbols;return{create:function(){var e=Object.create(this),t="string"==typeof e.__init?e.__init:"init";return"function"==typeof e[t]&&e[t].apply(e,arguments),e},mixin:function(t,n){var r=n||this,o=/\b_super\b/,i=Object.getPrototypeOf(r)||r.prototype,s={},c=t,a=function(e){var t=Object.getOwnPropertyDescriptor(c,e);!s[e]&&t&&(s[e]=t)};do{Object.getOwnPropertyNames(c).forEach(a),e&&Object.getOwnPropertySymbols(c).forEach(a)}while((c=Object.getPrototypeOf(c))&&Object.getPrototypeOf(c));var u=function(t){var n=s[t];"function"==typeof n.value&&o.test(n.value)&&(n.value=function(t,n,r,o){var i="function"==typeof n,s=function(){var e=this._super;this._super=i?n:t[r];var s=o.apply(this,arguments);return this._super=e,s};return i&&(Object.keys(n).forEach((function(e){s[e]=n[e]})),e&&Object.getOwnPropertySymbols(n).forEach((function(e){s[e]=n[e]}))),s}(i,r[t],t,n.value)),Object.defineProperty(r,t,n)};return Object.keys(s).forEach(u),e&&Object.getOwnPropertySymbols(s).forEach(u),r},extend:function(e,t){return this.mixin(e,Object.create(t||this))},proxy:function(e){var t=this[e],n=Array.prototype.slice.call(arguments,1);return n.unshift(this),t.bind.apply(t,n)}}})?n.apply(t,[]):n)&&(e.exports=t)}},t={},function n(r){var o=t[r];return void 0===o&&(o=t[r]={exports:{}},e[r].call(o.exports,o,o.exports,n)),o.exports}(630);var e,t}));
package/dist/feathers.js CHANGED
@@ -1673,7 +1673,7 @@ var application = {
1673
1673
  throw new Error('Registering a new service with `app.service(path, service)` is no longer supported. Use `app.use(path, service)` instead.');
1674
1674
  }
1675
1675
  var location = stripSlashes(path) || '/';
1676
- var current = this.services[location];
1676
+ var current = this.services.hasOwnProperty(location) ? this.services[location] : undefined;
1677
1677
  if (typeof current === 'undefined' && typeof this.defaultService === 'function') {
1678
1678
  return this.use(location, this.defaultService(location)).service(location);
1679
1679
  }
@@ -2113,7 +2113,7 @@ module.exports["default"] = createApplication;
2113
2113
  \**********************************/
2114
2114
  /***/ (function(module) {
2115
2115
 
2116
- module.exports = '4.5.16';
2116
+ module.exports = 'development';
2117
2117
 
2118
2118
  /***/ }),
2119
2119
 
@@ -3728,18 +3728,23 @@ var ThrowTypeError = $gOPD
3728
3728
  : throwTypeError;
3729
3729
 
3730
3730
  var hasSymbols = __webpack_require__(/*! has-symbols */ "../../node_modules/has-symbols/index.js")();
3731
+ var hasProto = __webpack_require__(/*! has-proto */ "../../node_modules/has-proto/index.js")();
3731
3732
 
3732
- var getProto = Object.getPrototypeOf || function (x) { return x.__proto__; }; // eslint-disable-line no-proto
3733
+ var getProto = Object.getPrototypeOf || (
3734
+ hasProto
3735
+ ? function (x) { return x.__proto__; } // eslint-disable-line no-proto
3736
+ : null
3737
+ );
3733
3738
 
3734
3739
  var needsEval = {};
3735
3740
 
3736
- var TypedArray = typeof Uint8Array === 'undefined' ? undefined : getProto(Uint8Array);
3741
+ var TypedArray = typeof Uint8Array === 'undefined' || !getProto ? undefined : getProto(Uint8Array);
3737
3742
 
3738
3743
  var INTRINSICS = {
3739
3744
  '%AggregateError%': typeof AggregateError === 'undefined' ? undefined : AggregateError,
3740
3745
  '%Array%': Array,
3741
3746
  '%ArrayBuffer%': typeof ArrayBuffer === 'undefined' ? undefined : ArrayBuffer,
3742
- '%ArrayIteratorPrototype%': hasSymbols ? getProto([][Symbol.iterator]()) : undefined,
3747
+ '%ArrayIteratorPrototype%': hasSymbols && getProto ? getProto([][Symbol.iterator]()) : undefined,
3743
3748
  '%AsyncFromSyncIteratorPrototype%': undefined,
3744
3749
  '%AsyncFunction%': needsEval,
3745
3750
  '%AsyncGenerator%': needsEval,
@@ -3769,10 +3774,10 @@ var INTRINSICS = {
3769
3774
  '%Int32Array%': typeof Int32Array === 'undefined' ? undefined : Int32Array,
3770
3775
  '%isFinite%': isFinite,
3771
3776
  '%isNaN%': isNaN,
3772
- '%IteratorPrototype%': hasSymbols ? getProto(getProto([][Symbol.iterator]())) : undefined,
3777
+ '%IteratorPrototype%': hasSymbols && getProto ? getProto(getProto([][Symbol.iterator]())) : undefined,
3773
3778
  '%JSON%': typeof JSON === 'object' ? JSON : undefined,
3774
3779
  '%Map%': typeof Map === 'undefined' ? undefined : Map,
3775
- '%MapIteratorPrototype%': typeof Map === 'undefined' || !hasSymbols ? undefined : getProto(new Map()[Symbol.iterator]()),
3780
+ '%MapIteratorPrototype%': typeof Map === 'undefined' || !hasSymbols || !getProto ? undefined : getProto(new Map()[Symbol.iterator]()),
3776
3781
  '%Math%': Math,
3777
3782
  '%Number%': Number,
3778
3783
  '%Object%': Object,
@@ -3785,10 +3790,10 @@ var INTRINSICS = {
3785
3790
  '%Reflect%': typeof Reflect === 'undefined' ? undefined : Reflect,
3786
3791
  '%RegExp%': RegExp,
3787
3792
  '%Set%': typeof Set === 'undefined' ? undefined : Set,
3788
- '%SetIteratorPrototype%': typeof Set === 'undefined' || !hasSymbols ? undefined : getProto(new Set()[Symbol.iterator]()),
3793
+ '%SetIteratorPrototype%': typeof Set === 'undefined' || !hasSymbols || !getProto ? undefined : getProto(new Set()[Symbol.iterator]()),
3789
3794
  '%SharedArrayBuffer%': typeof SharedArrayBuffer === 'undefined' ? undefined : SharedArrayBuffer,
3790
3795
  '%String%': String,
3791
- '%StringIteratorPrototype%': hasSymbols ? getProto(''[Symbol.iterator]()) : undefined,
3796
+ '%StringIteratorPrototype%': hasSymbols && getProto ? getProto(''[Symbol.iterator]()) : undefined,
3792
3797
  '%Symbol%': hasSymbols ? Symbol : undefined,
3793
3798
  '%SyntaxError%': $SyntaxError,
3794
3799
  '%ThrowTypeError%': ThrowTypeError,
@@ -3804,12 +3809,14 @@ var INTRINSICS = {
3804
3809
  '%WeakSet%': typeof WeakSet === 'undefined' ? undefined : WeakSet
3805
3810
  };
3806
3811
 
3807
- try {
3808
- null.error; // eslint-disable-line no-unused-expressions
3809
- } catch (e) {
3810
- // https://github.com/tc39/proposal-shadowrealm/pull/384#issuecomment-1364264229
3811
- var errorProto = getProto(getProto(e));
3812
- INTRINSICS['%Error.prototype%'] = errorProto;
3812
+ if (getProto) {
3813
+ try {
3814
+ null.error; // eslint-disable-line no-unused-expressions
3815
+ } catch (e) {
3816
+ // https://github.com/tc39/proposal-shadowrealm/pull/384#issuecomment-1364264229
3817
+ var errorProto = getProto(getProto(e));
3818
+ INTRINSICS['%Error.prototype%'] = errorProto;
3819
+ }
3813
3820
  }
3814
3821
 
3815
3822
  var doEval = function doEval(name) {
@@ -3827,7 +3834,7 @@ var doEval = function doEval(name) {
3827
3834
  }
3828
3835
  } else if (name === '%AsyncIteratorPrototype%') {
3829
3836
  var gen = doEval('%AsyncGenerator%');
3830
- if (gen) {
3837
+ if (gen && getProto) {
3831
3838
  value = getProto(gen.prototype);
3832
3839
  }
3833
3840
  }
@@ -4029,6 +4036,28 @@ module.exports = function GetIntrinsic(name, allowMissing) {
4029
4036
  };
4030
4037
 
4031
4038
 
4039
+ /***/ }),
4040
+
4041
+ /***/ "../../node_modules/has-proto/index.js":
4042
+ /*!*********************************************!*\
4043
+ !*** ../../node_modules/has-proto/index.js ***!
4044
+ \*********************************************/
4045
+ /***/ (function(module) {
4046
+
4047
+ "use strict";
4048
+
4049
+
4050
+ var test = {
4051
+ foo: {}
4052
+ };
4053
+
4054
+ var $Object = Object;
4055
+
4056
+ module.exports = function hasProto() {
4057
+ return { __proto__: test }.foo === test.foo && !({ __proto__: null } instanceof $Object);
4058
+ };
4059
+
4060
+
4032
4061
  /***/ }),
4033
4062
 
4034
4063
  /***/ "../../node_modules/has-symbols/index.js":
@@ -4936,7 +4965,8 @@ var isoSentinel = 'utf8=%26%2310003%3B'; // encodeURIComponent('&#10003;')
4936
4965
  var charsetSentinel = 'utf8=%E2%9C%93'; // encodeURIComponent('✓')
4937
4966
 
4938
4967
  var parseValues = function parseQueryStringValues(str, options) {
4939
- var obj = {};
4968
+ var obj = { __proto__: null };
4969
+
4940
4970
  var cleanStr = options.ignoreQueryPrefix ? str.replace(/^\?/, '') : str;
4941
4971
  var limit = options.parameterLimit === Infinity ? undefined : options.parameterLimit;
4942
4972
  var parts = cleanStr.split(options.delimiter, limit);
@@ -5180,7 +5210,6 @@ var arrayPrefixGenerators = {
5180
5210
  };
5181
5211
 
5182
5212
  var isArray = Array.isArray;
5183
- var split = String.prototype.split;
5184
5213
  var push = Array.prototype.push;
5185
5214
  var pushToArray = function (arr, valueOrArray) {
5186
5215
  push.apply(arr, isArray(valueOrArray) ? valueOrArray : [valueOrArray]);
@@ -5282,14 +5311,6 @@ var stringify = function stringify(
5282
5311
  if (isNonNullishPrimitive(obj) || utils.isBuffer(obj)) {
5283
5312
  if (encoder) {
5284
5313
  var keyValue = encodeValuesOnly ? prefix : encoder(prefix, defaults.encoder, charset, 'key', format);
5285
- if (generateArrayPrefix === 'comma' && encodeValuesOnly) {
5286
- var valuesArray = split.call(String(obj), ',');
5287
- var valuesJoined = '';
5288
- for (var i = 0; i < valuesArray.length; ++i) {
5289
- valuesJoined += (i === 0 ? '' : ',') + formatter(encoder(valuesArray[i], defaults.encoder, charset, 'value', format));
5290
- }
5291
- return [formatter(keyValue) + (commaRoundTrip && isArray(obj) && valuesArray.length === 1 ? '[]' : '') + '=' + valuesJoined];
5292
- }
5293
5314
  return [formatter(keyValue) + '=' + formatter(encoder(obj, defaults.encoder, charset, 'value', format))];
5294
5315
  }
5295
5316
  return [formatter(prefix) + '=' + formatter(String(obj))];
@@ -5304,6 +5325,9 @@ var stringify = function stringify(
5304
5325
  var objKeys;
5305
5326
  if (generateArrayPrefix === 'comma' && isArray(obj)) {
5306
5327
  // we need to join elements in
5328
+ if (encodeValuesOnly && encoder) {
5329
+ obj = utils.maybeMap(obj, encoder);
5330
+ }
5307
5331
  objKeys = [{ value: obj.length > 0 ? obj.join(',') || null : void undefined }];
5308
5332
  } else if (isArray(filter)) {
5309
5333
  objKeys = filter;
@@ -5336,7 +5360,7 @@ var stringify = function stringify(
5336
5360
  commaRoundTrip,
5337
5361
  strictNullHandling,
5338
5362
  skipNulls,
5339
- encoder,
5363
+ generateArrayPrefix === 'comma' && encodeValuesOnly && isArray(obj) ? null : encoder,
5340
5364
  filter,
5341
5365
  sort,
5342
5366
  allowDots,