!function(t){if("function"==typeofbootstrap)bootstrap("nedb",t);elseif("object"==typeofexports)module.exports=t();elseif("function"==typeofdefine&&define.amd)define(t);elseif("undefined"!=typeofses){if(!ses.ok())return;ses.makeNedb=t}else"undefined"!=typeofwindow?window.Nedb=t():global.Nedb=t()}(function(){vart;returnfunction(t,e,n){functionr(n,o){if(!e[n]){if(!t[n]){varu="function"==typeofrequire&&require;if(!o&&u)returnu(n,!0);if(i)returni(n,!0);thrownewError("Cannot find module '"+n+"'")}vara=e[n]={exports:{}};t[n][0].call(a.exports,function(e){vari=t[n][1][e];returnr(i?i:e)},a,a.exports)}returne[n].exports}for(vari="function"==typeofrequire&&require,o=0;o<n.length;o++)r(n[o]);returnr}({1:[function(t,e,n){functionr(t,e){if(t.indexOf)returnt.indexOf(e);for(varn=0;n<t.length;n++)if(e===t[n])returnn;return-1}vari=t("__browserify_process");i.EventEmitter||(i.EventEmitter=function(){});varo=n.EventEmitter=i.EventEmitter,u="function"==typeofArray.isArray?Array.isArray:function(t){return"[object Array]"===Object.prototype.toString.call(t)},a=10;o.prototype.setMaxListeners=function(t){this._events||(this._events={}),this._events.maxListeners=t},o.prototype.emit=function(t){if("error"===t&&(!this._events||!this._events.error||u(this._events.error)&&!this._events.error.length))throwarguments[1]instanceofError?arguments[1]:newError("Uncaught, unspecified 'error' event.");if(!this._events)return!1;vare=this._events[t];if(!e)return!1;if("function"==typeofe){switch(arguments.length){case1:e.call(this);break;case2:e.call(this,arguments[1]);break;case3:e.call(this,arguments[1],arguments[2]);break;default:varn=Array.prototype.slice.call(arguments,1);e.apply(this,n)}return!0}if(u(e)){for(varn=Array.prototype.slice.call(arguments,1),r=e.slice(),i=0,o=r.length;o>i;i++)r[i].apply(this,n);return!0}return!1},o.prototype.addListener=function(t,e){if("function"!=typeofe)thrownewError("addListener only takes instances of Function");if(this._events||(this._events={}),this.emit("newListener",t,e),this._events[t])if(u(this._events[t])){if(!this._events[t].warned){varn;n=void0!==this._events.maxListeners?this._events.maxListeners:a,n&&n>0&&this._events[t].length>n&&(this._events[t].warned=!0,console.error("(node) warning: possible EventEmitter memory leak detected. %d listeners added. Use emitter.setMaxListeners() to increase limit.",this._events[t].length),console.trace())}this._events[t].push(e)}elsethis._events[t]=[this._events[t],e];elsethis._events[t]=e;returnthis},o.prototype.on=o.prototype.addListener,o.prototype.once=function(t,e){varn=this;returnn.on(t,functionr(){n.removeListener(t,r),e.apply(this,arguments)}),this},o.prototype.removeListener=function(t,e){if("function"!=typeofe)thrownewError("removeListener only takes instances of Function");if(!this._events||!this._events[t])returnthis;varn=this._events[t];if(u(n)){vari=r(n,e);if(0>i)returnthis;n.splice(i,1),0==n.length&&deletethis._events[t]}elsethis._events[t]===e&&deletethis._events[t];returnthis},o.prototype.removeAllListeners=function(t){return0===arguments.length?(this._events={},this):(t&&this._events&&this._events[t]&&(this._events[t]=null),this)},o.prototype.listeners=function(t){returnthis._events||(this._events={}),this._events[t]||(this._events[t]=[]),u(this._events[t])||(this._events[t]=[this._events[t]]),this._events[t]},o.listenerCount=function(t,e){varn;returnn=t._events&&t._events[e]?"function"==typeoft._events[e]?1:t._events[e].length:0}},{__browserify_process:3}],2:[function(t,e,n){functionr(t){returnArray.isArray(t)||"object"==typeoft&&"[object Array]"===Object.prototype.toString.call(t)}functioni(t){"object"==typeoft&&"[object RegExp]"===Object.prototype.toString.call(t)}functiono(t){return"object"==typeoft&&"[object Date]"===Object.prototype.toString.call(t)}t("events"),n.isArray=r,n.isDate=function(t){return"[object Date]"===Object.prototype.toString.call(t)},n.isRegExp=function(t){return"[object RegExp]"===Object.prototype.toString.call(t)},n.print=function(){},n.puts=function(){},n.debu
}})},u.waterfall=function(t,e){if(e=e||function(){},t.constructor!==Array){varn=newError("First argument to waterfall must be an array of functions");returne(n)}if(!t.length)returne();varr=function(t){returnfunction(n){if(n)e.apply(null,arguments),e=function(){};else{vari=Array.prototype.slice.call(arguments,1),o=t.next();o?i.push(r(o)):i.push(e),u.setImmediate(function(){t.apply(null,i)})}}};r(u.iterator(t))()};varw=function(t,e,n){if(n=n||function(){},e.constructor===Array)t.map(e,function(t,e){t&&t(function(t){varn=Array.prototype.slice.call(arguments,1);n.length<=1&&(n=n[0]),e.call(null,t,n)})},n);else{varr={};t.each(f(e),function(t,n){e[t](function(e){vari=Array.prototype.slice.call(arguments,1);i.length<=1&&(i=i[0]),r[t]=i,n(e)})},function(t){n(t,r)})}};u.parallel=function(t,e){w({map:u.map,each:u.each},t,e)},u.parallelLimit=function(t,e,n){w({map:g(e),each:l(e)},t,n)},u.series=function(t,e){if(e=e||function(){},t.constructor===Array)u.mapSeries(t,function(t,e){t&&t(function(t){varn=Array.prototype.slice.call(arguments,1);n.length<=1&&(n=n[0]),e.call(null,t,n)})},e);else{varn={};u.eachSeries(f(t),function(e,r){t[e](function(t){vari=Array.prototype.slice.call(arguments,1);i.length<=1&&(i=i[0]),n[e]=i,r(t)})},function(t){e(t,n)})}},u.iterator=function(t){vare=function(n){varr=function(){returnt.length&&t[n].apply(null,arguments),r.next()};returnr.next=function(){returnn<t.length-1?e(n+1):null},r};returne(0)},u.apply=function(t){vare=Array.prototype.slice.call(arguments,1);returnfunction(){returnt.apply(null,e.concat(Array.prototype.slice.call(arguments)))}};vark=function(t,e,n,r){vari=[];t(e,function(t,e){n(t,function(t,n){i=i.concat(n||[]),e(t)})},function(t){r(t,i)})};u.concat=h(k),u.concatSeries=y(k),u.whilst=function(t,e,n){t()?e(function(r){returnr?n(r):(u.whilst(t,e,n),void0)}):n()},u.doWhilst=function(t,e,n){t(function(r){returnr?n(r):(e()?u.doWhilst(t,e,n):n(),void0)})},u.until=function(t,e,n){t()?n():e(function(r){returnr?n(r):(u.until(t,e,n),void0)})},u.doUntil=function(t,e,n){t(function(r){returnr?n(r):(e()?n():u.doUntil(t,e,n),void0)})},u.queue=function(t,n){functionr(t,e,r,i){e.constructor!==Array&&(e=[e]),a(e,function(e){varo={data:e,callback:"function"==typeofi?i:null};r?t.tasks.unshift(o):t.tasks.push(o),t.saturated&&t.tasks.length===n&&t.saturated(),u.setImmediate(t.process)})}void0===n&&(n=1);vari=0,o={tasks:[],concurrency:n,saturated:null,empty:null,drain:null,push:function(t,e){r(o,t,!1,e)},unshift:function(t,e){r(o,t,!0,e)},process:function(){if(i<o.concurrency&&o.tasks.length){varn=o.tasks.shift();o.empty&&0===o.tasks.length&&o.empty(),i+=1;varr=function(){i-=1,n.callback&&n.callback.apply(n,arguments),o.drain&&0===o.tasks.length+i&&o.drain(),o.process()},u=e(r);t(n.data,u)}},length:function(){returno.tasks.length},running:function(){returni}};returno},u.cargo=function(t,e){varn=!1,r=[],i={tasks:r,payload:e,saturated:null,empty:null,drain:null,push:function(t,n){t.constructor!==Array&&(t=[t]),a(t,function(t){r.push({data:t,callback:"function"==typeofn?n:null}),i.saturated&&r.length===e&&i.saturated()}),u.setImmediate(i.process)},process:functiono(){if(!n){if(0===r.length)returni.drain&&i.drain(),void0;varu="number"==typeofe?r.splice(0,e):r.splice(0),c=s(u,function(t){returnt.data});i.empty&&i.empty(),n=!0,t(c,function(){n=!1;vart=arguments;a(u,function(e){e.callback&&e.callback.apply(null,t)}),o()})}},length:function(){returnr.length},running:function(){returnn}};returni};varx=function(t){returnfunction(e){varn=Array.prototype.slice.call(arguments,1);e.apply(null,n.concat([function(e){varn=Array.prototype.slice.call(arguments,1);"undefined"!=typeofconsole&&(e?console.error&&console.error(e):console[t]&&a(n,function(e){console[t](e)}))}]))}};u.log=x("log"),u.dir=x("dir"),u.memoize=function(t,e){varn={},r={};e=e||function(t){returnt};vari=function(){vari=Array.prototype.slice.call(arguments),o=i.pop(),u=e.apply(null,i);uinn?o.apply(null,n[u]):uinr?r[u].push(o):(r[u]=[o],t.apply(null,i.concat([function(){n[u]=arguments;vart=r[u];