glynnbird closed pull request #142: 141 stream callbacks
URL: https://github.com/apache/couchdb-nano/pull/142
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git a/.travis.yml b/.travis.yml
index 16fbe4d..df4534b 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -9,5 +9,7 @@ os:
   - linux
 before_script:
   - ./scripts/run_couchdb_on_travis.sh
+after_script:
+  - ./scripts/stop_couchdb_on_travis.sh
 before_install:
   - npm update -g npm
diff --git a/README.md b/README.md
index 9a1e6b3..e89e444 100644
--- a/README.md
+++ b/README.md
@@ -37,14 +37,14 @@ See [Migration Guide for switching from Nano 6.x to 
7.x](migration_6_to_7.md).
   - [nano.db.get(name, [callback])](#nanodbgetname-callback)
   - [nano.db.destroy(name, [callback])](#nanodbdestroyname-callback)
   - [nano.db.list([callback])](#nanodblistcallback)
-  - [nano.db.listAsStream([callback])](#nanodblistasstreamcallback)
+  - [nano.db.listAsStream()](#nanodblistasstream)
   - [nano.db.compact(name, [designname], 
[callback])](#nanodbcompactname-designname-callback)
   - [nano.db.replicate(source, target, [opts], 
[callback])](#nanodbreplicatesource-target-opts-callback)
   - [nano.db.replication.enable(source, target, [opts], 
[callback])](#nanodbreplicationenablesource-target-opts-callback)
   - [nano.db.replication.query(id, [opts], 
[callback])](#nanodbreplicationenablesource-target-opts-callback)
   - [nano.db.replication.disable(id, [opts], 
[callback])](#nanodbreplicationdisableid-opts-callback)
   - [nano.db.changes(name, [params], 
[callback])](#nanodbchangesname-params-callback)
-  - [nano.db.changesAsStream(name, [params], 
[callback])](#nanodbchangesasstreamname-params-callback)
+  - [nano.db.changesAsStream(name, 
[params])](#nanodbchangesasstreamname-params)
   - [nano.db.follow(name, [params], 
[callback])](#nanodbfollowname-params-callback)
   - [nano.db.info([callback])](#nanodbinfocallback)
   - [nano.use(name)](#nanousename)
@@ -60,7 +60,7 @@ See [Migration Guide for switching from Nano 6.x to 
7.x](migration_6_to_7.md).
   - [db.copy(src_doc, dest_doc, opts, 
[callback])](#dbcopysrc_doc-dest_doc-opts-callback)
   - [db.bulk(docs, [params], [callback])](#dbbulkdocs-params-callback)
   - [db.list([params], [callback])](#dblistparams-callback)
-  - [db.listAsStream([params], [callback])](#dblistasstreamparams-callback)
+  - [db.listAsStream([params])](#dblistasstreamparams)
   - [db.fetch(docnames, [params], 
[callback])](#dbfetchdocnames-params-callback)
   - [db.fetchRevs(docnames, [params], 
[callback])](#dbfetchrevsdocnames-params-callback)
   - [db.createIndex(indexDef, [callback])](#dbcreateindexindexdef-callback)
@@ -69,19 +69,19 @@ See [Migration Guide for switching from Nano 6.x to 
7.x](migration_6_to_7.md).
   - [db.multipart.get(docname, [params], 
[callback])](#dbmultipartgetdocname-params-callback)
 - [Attachments functions](#attachments-functions)
   - [db.attachment.insert(docname, attname, att, contenttype, [params], 
[callback])](#dbattachmentinsertdocname-attname-att-contenttype-params-callback)
-  - [db.attachment.insertAsStream(docname, attname, att, contenttype, 
[params], 
[callback])](#dbattachmentinsertasstreamdocname-attname-att-contenttype-params-callback)
+  - [db.attachment.insertAsStream(docname, attname, att, contenttype, 
[params])](#dbattachmentinsertasstreamdocname-attname-att-contenttype-params)
   - [db.attachment.get(docname, attname, [params], 
[callback])](#dbattachmentgetdocname-attname-params-callback)
-  - [db.attachment.getAsStream(docname, attname, [params], 
[callback])](#dbattachmentgetasstreamdocname-attname-params-callback)
+  - [db.attachment.getAsStream(docname, attname, 
[params])](#dbattachmentgetasstreamdocname-attname-params)
   - [db.attachment.destroy(docname, attname, [params], 
[callback])](#dbattachmentdestroydocname-attname-params-callback)
 - [Views and design functions](#views-and-design-functions)
   - [db.view(designname, viewname, [params], 
[callback])](#dbviewdesignname-viewname-params-callback)
-  - [db.viewAsStream(designname, viewname, [params], 
[callback])](#dbviewasstreamdesignname-viewname-params-callback)
+  - [db.viewAsStream(designname, viewname, 
[params])](#dbviewasstreamdesignname-viewname-params)
   - [db.show(designname, showname, doc_id, [params], 
[callback])](#dbshowdesignname-showname-doc_id-params-callback)
   - [db.atomic(designname, updatename, docname, [body], 
[callback])](#dbatomicdesignname-updatename-docname-body-callback)
   - [db.search(designname, viewname, params, 
[callback])](#dbsearchdesignname-searchname-params-callback)
-  - [db.searchAsStream(designname, viewname, params, 
[callback])](#dbsearchasstreamdesignname-searchname-params-callback)
+  - [db.searchAsStream(designname, viewname, 
params)](#dbsearchasstreamdesignname-searchname-params)
   - [db.find(selector, [callback])](#dbfindselector-callback)
-  - [db.findAsStream(selector, [callback])](#dbfindasstreamselector-callback)
+  - [db.findAsStream(selector)](#dbfindasstreamselector)
 - [Using cookie authentication](#using-cookie-authentication)
 - [Advanced features](#advanced-features)
   - [getting uuids](#getting-uuids)
@@ -343,7 +343,7 @@ nano.db.list().then((body) => {
 });
 ```
 
-### nano.db.listAsStream([callback])
+### nano.db.listAsStream()
 
 Lists all the CouchDB databases as a stream:
 
@@ -420,9 +420,9 @@ nano.db.changes('alice').then((body) => {
 });
 ```
 
-### nano.db.changesAsStream(name, [params], [callback])
+### nano.db.changesAsStream(name, [params])
 
-Sames as `nano.db.changes` but returns a stream.
+Same as `nano.db.changes` but returns a stream.
 
 ```js
 nano.db.changes('alice').pipe(process.stdout);
@@ -656,7 +656,7 @@ alice.list({include_docs: true}).then((body) => {
 });
 ```
 
-### db.listAsStream([params], [callback])
+### db.listAsStream([params])
 
 List all the docs in the database as a stream.
 
@@ -753,7 +753,7 @@ fs.readFile('rabbit.png', (err, data) => {
 });
 ```
 
-### db.attachment.insertAsStream(docname, attname, att, contenttype, [params], 
[callback])
+### db.attachment.insertAsStream(docname, attname, att, contenttype, [params])
 
 It may be more memory-efficient to pipe a stream of data from a source (file, 
network etc) to a CouchDB attachment:
 
@@ -779,7 +779,7 @@ alice.attachment.get('rabbit', 'rabbit.png').then((body) => 
{
 });
 ```
 
-### db.attachment.getAsStream(docname, attname, [params], [callback])
+### db.attachment.getAsStream(docname, attname, [params])
 
 ```js
 const fs = require('fs');
@@ -848,7 +848,7 @@ alice.view('characters', 'happy_ones', { include_docs: true 
}).then((body) => {
 });
 ```
 
-### db.viewAsStream(designname, viewname, [params], [callback])
+### db.viewAsStream(designname, viewname, [params])
 
 Same as `db.view` but returns a stream:
 
@@ -920,7 +920,7 @@ alice.search('characters', 'happy_ones', { q: 'cat' 
}).then((doc) => {
 
 Check out the tests for a fully functioning example.
 
-### db.searchAsStream(designname, searchname, params, [callback])
+### db.searchAsStream(designname, searchname, params)
 
 Calls a view of the specified design with optional query string additions 
`params`. Returns stream.
 
@@ -947,7 +947,7 @@ alice.find(q).then((doc) => {
 });
 ```
 
-### db.findAsStream(selector, [callback])
+### db.findAsStream(selector)
 
 Perform a ["Mango" 
query](http://docs.couchdb.org/en/2.1.1/api/database/find.html) by supplying a 
JavaScript object containing a selector, but return a stream:
 
diff --git a/lib/nano.d.ts b/lib/nano.d.ts
index e00fade..e02154e 100644
--- a/lib/nano.d.ts
+++ b/lib/nano.d.ts
@@ -61,7 +61,7 @@ declare namespace nano {
     destroy(name: string, callback?: Callback<OkResponse>): 
Promise<OkResponse>;
     // http://docs.couchdb.org/en/latest/api/server/common.html#get--_all_dbs
     list(callback?: Callback<string[]>): Promise<string[]>;
-    listAsStream(callback?: Callback<string[]>): Request;
+    listAsStream(): Request;
     use<D>(db: string): DocumentScope<D>;
     compact(name: string, callback?: Callback<OkResponse>): 
Promise<OkResponse>;
     // 
http://docs.couchdb.org/en/latest/api/database/compact.html#post--db-_compact
@@ -84,9 +84,9 @@ declare namespace nano {
     // 
http://docs.couchdb.org/en/latest/api/database/compact.html#post--db-_compact
     changes(name: string, params: DatabaseChangesParams, callback?: 
Callback<DatabaseChangesResponse>): Promise<DatabaseChangesResponse>;
     // 
http://docs.couchdb.org/en/latest/api/database/changes.html#get--db-_changes
-    changesAsStream(name: string, callback?: 
Callback<DatabaseChangesResponse>): Request;
+    changesAsStream(name: string): Request;
     // 
http://docs.couchdb.org/en/latest/api/database/compact.html#post--db-_compact
-    changesAsStream(name: string, params: DatabaseChangesParams, callback?: 
Callback<DatabaseChangesResponse>): Request;
+    changesAsStream(name: string, params: DatabaseChangesParams): Request;
     follow(source: string, callback?: Callback<any>): EventEmitter;
     follow(source: string, params: DatabaseScopeFollowUpdatesParams, 
callback?: Callback<any>): EventEmitter;
     followUpdates(params?: any, callback?: Callback<any>): EventEmitter;
@@ -157,9 +157,9 @@ declare namespace nano {
     // 
http://docs.couchdb.org/en/latest/api/database/bulk-api.html#get--db-_all_docs
     list(params: DocumentListParams, callback?: 
Callback<DocumentListResponse<D>>): Promise<DocumentListResponse<D>>;
     // 
http://docs.couchdb.org/en/latest/api/database/bulk-api.html#get--db-_all_docs
-    listAsStream(callback?: Callback<Request>): Request;
+    listAsStream(): Request;
     // 
http://docs.couchdb.org/en/latest/api/database/bulk-api.html#get--db-_all_docs
-    listAsStream(params: DocumentListParams, callback?: Callback<Request>): 
Request;
+    listAsStream(params: DocumentListParams): Request;
     // 
http://docs.couchdb.org/en/latest/api/database/bulk-api.html#post--db-_all_docs
     fetch(docnames: BulkFetchDocsWrapper, callback?: 
Callback<DocumentFetchResponse<D>>): Promise<DocumentFetchResponse<D>>;
     // 
http://docs.couchdb.org/en/latest/api/database/bulk-api.html#post--db-_all_docs
@@ -232,8 +232,7 @@ declare namespace nano {
     searchAsStream<V>(
       designname: string,
       searchname: string,
-      params: DocumentSearchParams,
-      callback?: Callback<DocumentSearchResponse<V>>
+      params: DocumentSearchParams
     ): Request;
     // 
http://docs.couchdb.org/en/latest/api/ddoc/views.html#get--db-_design-ddoc-_view-view
     // 
http://docs.couchdb.org/en/latest/api/ddoc/views.html#post--db-_design-ddoc-_view-view
@@ -241,7 +240,7 @@ declare namespace nano {
       designname: string,
       viewname: string,
       callback?: Callback<DocumentViewResponse<V,D>>
-    ): Promise<DocumentViewResponse<V,D>>; 
+    ): Promise<DocumentViewResponse<V,D>>;
     // 
http://docs.couchdb.org/en/latest/api/ddoc/views.html#get--db-_design-ddoc-_view-view
     // 
http://docs.couchdb.org/en/latest/api/ddoc/views.html#post--db-_design-ddoc-_view-view
     view<V>(
@@ -254,17 +253,15 @@ declare namespace nano {
     // 
http://docs.couchdb.org/en/latest/api/ddoc/views.html#post--db-_design-ddoc-_view-view
     viewAsStream<V>(
       designname: string,
-      viewname: string,
-      callback?: Callback<DocumentViewResponse<V,D>>
-    ): Request; 
+      viewname: string
+    ): Request;
     // 
http://docs.couchdb.org/en/latest/api/ddoc/views.html#get--db-_design-ddoc-_view-view
     // 
http://docs.couchdb.org/en/latest/api/ddoc/views.html#post--db-_design-ddoc-_view-view
     viewAsStream<V>(
       designname: string,
       viewname: string,
-      params: DocumentViewParams,
-      callback?: Callback<DocumentViewResponse<V,D>>
-    ): Request;    
+      params: DocumentViewParams
+    ): Request;
     // 
http://docs.couchdb.org/en/latest/api/ddoc/render.html#db-design-design-doc-list-list-name-view-name
     viewWithList(
       designname: string,
@@ -322,16 +319,14 @@ declare namespace nano {
       docname: string,
       attname: string,
       att: any,
-      contenttype: string,
-      callback?: Callback<DocumentInsertResponse>
+      contenttype: string
     ): Request;
     insertAsStream(
       docname: string,
       attname: string,
       att: any,
       contenttype: string,
-      params: any,
-      callback?: Callback<DocumentInsertResponse>
+      params: any
     ): Request
     get(docname: string, attname: string, callback?: Callback<any>): 
Promise<any>;
     getAsStream(docname: string, attname: string): Request;
@@ -908,7 +903,7 @@ declare namespace nano {
     key?: string;
 
     // Return only documents that match the specified keys.
-    keys?: string | string[]; 
+    keys?: string | string[];
 
     // Limit the number of the returned documents to the specified number.
     limit?: number;
@@ -1013,7 +1008,7 @@ declare namespace nano {
     // A bookmark that was received from a previous search. Used for 
pagination.
     bookmark?: string;
 
-    // An array of field names for which facet counts are requested. 
+    // An array of field names for which facet counts are requested.
     counts?: string[];
 
     // Filters the result set using key value pairs supplied to the drilldown 
parameter.
@@ -1025,7 +1020,7 @@ declare namespace nano {
     // The maximum group count when used in conjunction with group_field.
     group_limit?: number;
 
-    // Defines the order of the groups in a search when used with group_field. 
+    // Defines the order of the groups in a search when used with group_field.
     group_sort?: string | string[];
 
     // Which fields are to be highlighted.
@@ -1039,7 +1034,7 @@ declare namespace nano {
 
     // The number of gradments that are returned in highlights. Defaults to 1.
     highlight_number?: number;
-    
+
     // The number of characters in each fragment for highlight. Defaults to 
100.
     highlight_size?: number;
 
@@ -1061,7 +1056,7 @@ declare namespace nano {
     // Defines ranges for faceted numeric search fields.
     ranges?: object;
 
-    // Specifies the sort order of the results. 
+    // Specifies the sort order of the results.
     sort?: string | string[];
 
     // Do not wait for the index to finish building to return results.
@@ -1263,4 +1258,4 @@ declare namespace nano {
   }
 }
 
-export = nano;
\ No newline at end of file
+export = nano;
diff --git a/lib/nano.js b/lib/nano.js
index 3911d81..8169b0d 100644
--- a/lib/nano.js
+++ b/lib/nano.js
@@ -279,7 +279,7 @@ module.exports = exports = function dbScope (cfg) {
 
     if (opts.stream) {
       // return the Request object for streaming
-      return httpAgent(req, responseHandler(req, opts, null, null, callback))
+      return httpAgent(req)
     } else {
       if (typeof callback === 'function') {
         // return nothing - feedback via the callback function
@@ -344,8 +344,8 @@ module.exports = exports = function dbScope (cfg) {
   }
 
   // http://docs.couchdb.org/en/latest/api/server/common.html#get--_all_dbs
-  function listDbsAsStream (callback) {
-    return relax({db: '_all_dbs', stream: true}, callback)
+  function listDbsAsStream () {
+    return relax({db: '_all_dbs', stream: true})
   }
 
   // 
http://docs.couchdb.org/en/latest/api/database/compact.html#post--db-_compact
@@ -368,15 +368,14 @@ module.exports = exports = function dbScope (cfg) {
     return relax({db: dbName, path: '_changes', qs: opts}, callback)
   }
 
-  function changesDbAsStream (dbName, qs0, callback0) {
-    const {opts, callback} = getCallback(qs0, callback0)
-    return relax({db: dbName, path: '_changes', stream: true, qs: opts}, 
callback)
+  function changesDbAsStream (dbName, opts) {
+    return relax({db: dbName, path: '_changes', stream: true, qs: opts})
   }
 
   function followDb (dbName, qs0, callback0) {
     const {opts, callback} = getCallback(qs0, callback0)
     opts.db = urlResolveFix(cfg.url, encodeURIComponent(dbName))
-    opts.httpAgent = httpAgent;
+    opts.httpAgent = httpAgent
     if (typeof callback === 'function') {
       return followAgent(opts, callback)
     } else {
@@ -511,7 +510,7 @@ module.exports = exports = function dbScope (cfg) {
           doc: docName,
           method: 'HEAD',
           qs: {}
-        }, callback);
+        }, callback)
       } else {
         // this function doesn't pass on the Promise from relax because it 
needs
         // to return the headers when resolving the Promise
@@ -523,12 +522,12 @@ module.exports = exports = function dbScope (cfg) {
             qs: {}
           }, function (err, body, headers) {
             if (err) {
-              reject(err);
+              reject(err)
             } else {
-              resolve(headers);
+              resolve(headers)
             }
-          });
-        });
+          })
+        })
       }
     }
 
@@ -544,16 +543,29 @@ module.exports = exports = function dbScope (cfg) {
       }
 
       if (opts.overwrite) {
-        return headDoc(docDest, function (e, b, h) {
-          if (e && e.statusCode !== 404) {
-            return callback(e)
-          }
-          if (h.etag) {
-            qs.headers.Destination += '?rev=' +
-              h.etag.substring(1, h.etag.length - 1)
+        const p = headDoc(docDest).then(
+          function (h) {
+            if (h.etag) {
+              qs.headers.Destination += '?rev=' +
+                h.etag.substring(1, h.etag.length - 1)
+            }
+            relax(qs, callback)
+          },
+          function (e) {
+            if (e && e.statusCode !== 404) {
+              if (callback) {
+                callback(e)
+              } else {
+                return Promise.reject(e)
+              }
+            } else {
+              relax(qs, callback)
+            }
           }
-          return relax(qs, callback)
-        })
+        )
+        if (!callback) {
+          return p
+        }
       } else {
         return relax(qs, callback)
       }
@@ -566,9 +578,8 @@ module.exports = exports = function dbScope (cfg) {
     }
 
     // 
http://docs.couchdb.org/en/latest/api/database/bulk-api.html#get--db-_all_docs
-    function listDocAsStream (qs0, callback0) {
-      const {opts, callback} = getCallback(qs0, callback0)
-      return relax({db: dbName, path: '_all_docs', qs: opts, stream: true}, 
callback)
+    function listDocAsStream (opts) {
+      return relax({db: dbName, path: '_all_docs', qs: opts, stream: true})
     }
 
     // 
http://docs.couchdb.org/en/latest/api/database/bulk-api.html#post--db-_all_docs
@@ -670,8 +681,8 @@ module.exports = exports = function dbScope (cfg) {
     }
 
     // 
http://docs.couchdb.org/en/latest/api/ddoc/views.html#post--db-_design-ddoc-_view-view
-    function viewDocsAsStream (ddoc, viewName, qs, callback) {
-      return view(ddoc, viewName, {type: 'view', stream: true}, qs, callback)
+    function viewDocsAsStream (ddoc, viewName, qs) {
+      return view(ddoc, viewName, {type: 'view', stream: true}, qs)
     }
 
     // cloudant
@@ -680,8 +691,8 @@ module.exports = exports = function dbScope (cfg) {
     }
 
     // cloudant
-    function viewSearchAsStream (ddoc, viewName, qs, callback) {
-      return view(ddoc, viewName, {type: 'search', stream: true}, qs, callback)
+    function viewSearchAsStream (ddoc, viewName, qs) {
+      return view(ddoc, viewName, {type: 'search', stream: true}, qs)
     }
 
     // 
http://docs.couchdb.org/en/latest/api/ddoc/render.html#get--db-_design-ddoc-_show-func
@@ -787,8 +798,7 @@ module.exports = exports = function dbScope (cfg) {
       }, callback)
     }
 
-    function insertAttAsStream (docName, attName, att, contentType, qs0, 
callback0) {
-      const {opts, callback} = getCallback(qs0, callback0)
+    function insertAttAsStream (docName, attName, att, contentType, opts) {
       return relax({
         db: dbName,
         att: attName,
@@ -799,7 +809,7 @@ module.exports = exports = function dbScope (cfg) {
         body: att,
         stream: true,
         dontStringify: true
-      }, callback)
+      })
     }
 
     function getAtt (docName, attName, qs0, callback0) {
@@ -814,8 +824,7 @@ module.exports = exports = function dbScope (cfg) {
       }, callback)
     }
 
-    function getAttAsStream (docName, attName, qs0, callback0) {
-      const {opts, callback} = getCallback(qs0, callback0)
+    function getAttAsStream (docName, attName, opts) {
       return relax({
         db: dbName,
         att: attName,
@@ -824,7 +833,7 @@ module.exports = exports = function dbScope (cfg) {
         stream: true,
         encoding: null,
         dontParse: true
-      }, callback)
+      })
     }
 
     function destroyAtt (docName, attName, qs, callback) {
@@ -846,14 +855,14 @@ module.exports = exports = function dbScope (cfg) {
       }, callback)
     }
 
-    function findAsStream (selector, callback) {
+    function findAsStream (selector) {
       return relax({
         db: dbName,
         path: '_find',
         method: 'POST',
         body: selector,
         stream: true
-      }, callback)
+      })
     }
 
     function createIndex (indexDef, callback) {
@@ -879,8 +888,8 @@ module.exports = exports = function dbScope (cfg) {
       changes: function (qs, cb) {
         return changesDb(dbName, qs, cb)
       },
-      changesAsStream: function (qs, cb) {
-        return changesDbAsStream(dbName, qs, cb)
+      changesAsStream: function (qs) {
+        return changesDbAsStream(dbName, qs)
       },
       follow: function (qs, cb) {
         return followDb(dbName, qs, cb)
diff --git a/package-lock.json b/package-lock.json
index d874bca..7748438 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -14,7 +14,7 @@
       "resolved": 
"https://registry.npmjs.org/@types/form-data/-/form-data-2.2.1.tgz";,
       "integrity": 
"sha512-JAMFhOaHIciYVh8fb5/83nmuO/AHwmto+Hq7a9y8FzLDcC1KCU344XDOMEmahnrTFlHjgh4L0WJFczNIX2GxnQ==",
       "requires": {
-        "@types/node": "*"
+        "@types/node": "10.7.0"
       }
     },
     "@types/node": {
@@ -27,10 +27,10 @@
       "resolved": 
"https://registry.npmjs.org/@types/request/-/request-2.47.1.tgz";,
       "integrity": 
"sha512-TV3XLvDjQbIeVxJ1Z3oCTDk/KuYwwcNKVwz2YaT0F5u86Prgc4syDAp6P96rkTQQ4bIdh+VswQIC9zS6NjY7/g==",
       "requires": {
-        "@types/caseless": "*",
-        "@types/form-data": "*",
-        "@types/node": "*",
-        "@types/tough-cookie": "*"
+        "@types/caseless": "0.12.1",
+        "@types/form-data": "2.2.1",
+        "@types/node": "10.7.0",
+        "@types/tough-cookie": "2.3.3"
       }
     },
     "@types/tough-cookie": {
@@ -56,7 +56,7 @@
       "integrity": "sha1-r9+UiPsezvyDSPb7IvRk4ypYs2s=",
       "dev": true,
       "requires": {
-        "acorn": "^3.0.4"
+        "acorn": "3.3.0"
       },
       "dependencies": {
         "acorn": {
@@ -72,10 +72,10 @@
       "resolved": "https://registry.npmjs.org/ajv/-/ajv-5.5.2.tgz";,
       "integrity": "sha1-c7Xuyj+rZT49P5Qis0GtQiBdyWU=",
       "requires": {
-        "co": "^4.6.0",
-        "fast-deep-equal": "^1.0.0",
-        "fast-json-stable-stringify": "^2.0.0",
-        "json-schema-traverse": "^0.3.0"
+        "co": "4.6.0",
+        "fast-deep-equal": "1.1.0",
+        "fast-json-stable-stringify": "2.0.0",
+        "json-schema-traverse": "0.3.1"
       }
     },
     "ajv-keywords": {
@@ -90,9 +90,9 @@
       "integrity": "sha1-DNkKVhCT810KmSVsIrcGlDP60Rc=",
       "dev": true,
       "requires": {
-        "kind-of": "^3.0.2",
-        "longest": "^1.0.1",
-        "repeat-string": "^1.5.2"
+        "kind-of": "3.2.2",
+        "longest": "1.0.1",
+        "repeat-string": "1.6.1"
       }
     },
     "amdefine": {
@@ -125,7 +125,7 @@
       "integrity": 
"sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==",
       "dev": true,
       "requires": {
-        "sprintf-js": "~1.0.2"
+        "sprintf-js": "1.0.3"
       }
     },
     "array-includes": {
@@ -134,8 +134,8 @@
       "integrity": "sha1-GEtI9i2S10UrsxsyMWXH+L0CJm0=",
       "dev": true,
       "requires": {
-        "define-properties": "^1.1.2",
-        "es-abstract": "^1.7.0"
+        "define-properties": "1.1.2",
+        "es-abstract": "1.12.0"
       }
     },
     "array-union": {
@@ -144,7 +144,7 @@
       "integrity": "sha1-mjRBDk9OPaI96jdb5b5w8kd47Dk=",
       "dev": true,
       "requires": {
-        "array-uniq": "^1.0.1"
+        "array-uniq": "1.0.3"
       }
     },
     "array-uniq": {
@@ -164,7 +164,7 @@
       "resolved": "https://registry.npmjs.org/asn1/-/asn1-0.2.4.tgz";,
       "integrity": 
"sha512-jxwzQpLQjSmWXgwaCZE9Nz+glAG01yF1QnWgbhGwHI5A6FRIEY6IVqtHhIepHqI7/kyEyQEagBC5mBEFlIYvdg==",
       "requires": {
-        "safer-buffer": "~2.1.0"
+        "safer-buffer": "2.1.2"
       }
     },
     "assert-plus": {
@@ -184,7 +184,7 @@
       "integrity": 
"sha512-fNEiL2+AZt6AlAw/29Cr0UDe4sRAHCpEHh54WMz+Bb7QfNcFw4h3loofyJpLeQs4Yx7yuqu/2dLgM5hKOs6HlQ==",
       "dev": true,
       "requires": {
-        "lodash": "^4.17.10"
+        "lodash": "4.17.10"
       }
     },
     "asynckit": {
@@ -208,9 +208,9 @@
       "integrity": "sha1-Y/1D99weO7fONZR9uP42mj9Yx0s=",
       "dev": true,
       "requires": {
-        "chalk": "^1.1.3",
-        "esutils": "^2.0.2",
-        "js-tokens": "^3.0.2"
+        "chalk": "1.1.3",
+        "esutils": "2.0.2",
+        "js-tokens": "3.0.2"
       },
       "dependencies": {
         "chalk": {
@@ -219,11 +219,11 @@
           "integrity": "sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg=",
           "dev": true,
           "requires": {
-            "ansi-styles": "^2.2.1",
-            "escape-string-regexp": "^1.0.2",
-            "has-ansi": "^2.0.0",
-            "strip-ansi": "^3.0.0",
-            "supports-color": "^2.0.0"
+            "ansi-styles": "2.2.1",
+            "escape-string-regexp": "1.0.5",
+            "has-ansi": "2.0.0",
+            "strip-ansi": "3.0.1",
+            "supports-color": "2.0.0"
           }
         },
         "strip-ansi": {
@@ -232,7 +232,7 @@
           "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=",
           "dev": true,
           "requires": {
-            "ansi-regex": "^2.0.0"
+            "ansi-regex": "2.1.1"
           }
         },
         "supports-color": {
@@ -255,7 +255,7 @@
       "integrity": "sha1-pDAdOJtqQ/m2f/PKEaP2Y342Dp4=",
       "optional": true,
       "requires": {
-        "tweetnacl": "^0.14.3"
+        "tweetnacl": "0.14.5"
       }
     },
     "brace-expansion": {
@@ -264,7 +264,7 @@
       "integrity": 
"sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==",
       "dev": true,
       "requires": {
-        "balanced-match": "^1.0.0",
+        "balanced-match": "1.0.0",
         "concat-map": "0.0.1"
       }
     },
@@ -291,7 +291,7 @@
       "integrity": "sha1-lAhe9jWB7NPaqSREqP6U6CV3dR8=",
       "dev": true,
       "requires": {
-        "callsites": "^0.2.0"
+        "callsites": "0.2.0"
       }
     },
     "callsites": {
@@ -319,8 +319,8 @@
       "dev": true,
       "optional": true,
       "requires": {
-        "align-text": "^0.1.3",
-        "lazy-cache": "^1.0.3"
+        "align-text": "0.1.4",
+        "lazy-cache": "1.0.4"
       }
     },
     "chai": {
@@ -329,12 +329,12 @@
       "integrity": "sha1-D2RYS6ZC8PKs4oBiefTwbKI61zw=",
       "dev": true,
       "requires": {
-        "assertion-error": "^1.0.1",
-        "check-error": "^1.0.1",
-        "deep-eql": "^3.0.0",
-        "get-func-name": "^2.0.0",
-        "pathval": "^1.0.0",
-        "type-detect": "^4.0.0"
+        "assertion-error": "1.1.0",
+        "check-error": "1.0.2",
+        "deep-eql": "3.0.1",
+        "get-func-name": "2.0.0",
+        "pathval": "1.1.0",
+        "type-detect": "4.0.8"
       }
     },
     "chalk": {
@@ -343,9 +343,9 @@
       "integrity": 
"sha512-ObN6h1v2fTJSmUXoS3nMQ92LbDK9be4TV+6G+omQlGJFdcUX5heKi1LZ1YnRMIgwTLEj3E24bT6tYni50rlCfQ==",
       "dev": true,
       "requires": {
-        "ansi-styles": "^3.2.1",
-        "escape-string-regexp": "^1.0.5",
-        "supports-color": "^5.3.0"
+        "ansi-styles": "3.2.1",
+        "escape-string-regexp": "1.0.5",
+        "supports-color": "5.4.0"
       },
       "dependencies": {
         "ansi-styles": {
@@ -354,7 +354,7 @@
           "integrity": 
"sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==",
           "dev": true,
           "requires": {
-            "color-convert": "^1.9.0"
+            "color-convert": "1.9.2"
           }
         },
         "has-flag": {
@@ -369,7 +369,7 @@
           "integrity": 
"sha512-zjaXglF5nnWpsq470jSv6P9DwPvgLkuapYmfDm3JWOm0vkNTVF2tI4UrN2r6jH1qM/uc/WtxYY1hYoA2dOKj5w==",
           "dev": true,
           "requires": {
-            "has-flag": "^3.0.0"
+            "has-flag": "3.0.0"
           }
         }
       }
@@ -398,7 +398,7 @@
       "integrity": "sha1-s12sN2R5+sw+lHR9QdDQ9SOP/LU=",
       "dev": true,
       "requires": {
-        "restore-cursor": "^2.0.0"
+        "restore-cursor": "2.0.0"
       }
     },
     "cli-width": {
@@ -414,8 +414,8 @@
       "dev": true,
       "optional": true,
       "requires": {
-        "center-align": "^0.1.1",
-        "right-align": "^0.1.1",
+        "center-align": "0.1.3",
+        "right-align": "0.1.3",
         "wordwrap": "0.0.2"
       },
       "dependencies": {
@@ -433,9 +433,9 @@
       "resolved": 
"https://registry.npmjs.org/cloudant-follow/-/cloudant-follow-0.18.0.tgz";,
       "integrity": 
"sha512-jsplCsI0EpJvTrlgeuuYFrmrKGxm8TlSkyKzOLZa6fc6p+FNT8UDPAwYeh0yaT8IdI+sxT5DTdCD2G45HWpSaw==",
       "requires": {
-        "browser-request": "~0.3.0",
-        "debug": "^4.0.1",
-        "request": "^2.88.0"
+        "browser-request": "0.3.3",
+        "debug": "4.1.0",
+        "request": "2.88.0"
       },
       "dependencies": {
         "debug": {
@@ -443,7 +443,7 @@
           "resolved": "https://registry.npmjs.org/debug/-/debug-4.1.0.tgz";,
           "integrity": 
"sha512-heNPJUJIqC+xB6ayLAMHaIrmN9HKa7aQO8MGqKpvCA+uJYVcvR6l5kgdrhRuwPFHU7P5/A1w0BjByPHwpfTDKg==",
           "requires": {
-            "ms": "^2.1.1"
+            "ms": "2.1.1"
           }
         },
         "ms": {
@@ -478,7 +478,7 @@
       "resolved": 
"https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.6.tgz";,
       "integrity": "sha1-cj599ugBrFYTETp+RFqbactjKBg=",
       "requires": {
-        "delayed-stream": "~1.0.0"
+        "delayed-stream": "1.0.0"
       }
     },
     "concat-map": {
@@ -493,10 +493,10 @@
       "integrity": 
"sha512-27HBghJxjiZtIk3Ycvn/4kbJk/1uZuJFfuPEns6LaEvpvG1f0hTea8lilrouyo9mVc2GWdcEZ8OLoGmSADlrCw==",
       "dev": true,
       "requires": {
-        "buffer-from": "^1.0.0",
-        "inherits": "^2.0.3",
-        "readable-stream": "^2.2.2",
-        "typedarray": "^0.0.6"
+        "buffer-from": "1.1.1",
+        "inherits": "2.0.3",
+        "readable-stream": "2.3.6",
+        "typedarray": "0.0.6"
       }
     },
     "contains-path": {
@@ -516,9 +516,9 @@
       "integrity": "sha1-6L0O/uWPz/b4+UUQoKVUu/ojVEk=",
       "dev": true,
       "requires": {
-        "lru-cache": "^4.0.1",
-        "shebang-command": "^1.2.0",
-        "which": "^1.2.9"
+        "lru-cache": "4.1.3",
+        "shebang-command": "1.2.0",
+        "which": "1.3.1"
       }
     },
     "dashdash": {
@@ -526,7 +526,7 @@
       "resolved": "https://registry.npmjs.org/dashdash/-/dashdash-1.14.1.tgz";,
       "integrity": "sha1-hTz6D3y+L+1d4gMmuN1YEDX24vA=",
       "requires": {
-        "assert-plus": "^1.0.0"
+        "assert-plus": "1.0.0"
       }
     },
     "debug": {
@@ -556,7 +556,7 @@
       "integrity": 
"sha512-+QeIQyN5ZuO+3Uk5DYh6/1eKO0m0YmJFGNmFHGACpf1ClL1nmlV/p4gNgbl2pJGxgXb4faqo6UE+M5ACEMyVcw==",
       "dev": true,
       "requires": {
-        "type-detect": "^4.0.0"
+        "type-detect": "4.0.8"
       }
     },
     "deep-equal": {
@@ -577,8 +577,8 @@
       "integrity": "sha1-g6c/L+pWmJj7c3GTyPhzyvbUXJQ=",
       "dev": true,
       "requires": {
-        "foreach": "^2.0.5",
-        "object-keys": "^1.0.8"
+        "foreach": "2.0.5",
+        "object-keys": "1.0.12"
       }
     },
     "defined": {
@@ -593,12 +593,12 @@
       "integrity": 
"sha512-2kjwuGGonL7gWE1XU4Fv79+vVzpoQCl0V+boMwWtOQJV2AGDabCwez++nB1Nli/8BabAfZQ/UuHPlp6AymKdWw==",
       "dev": true,
       "requires": {
-        "find-root": "^1.0.0",
-        "glob": "^7.0.5",
-        "ignore": "^3.0.9",
-        "pkg-config": "^1.1.0",
-        "run-parallel": "^1.1.2",
-        "uniq": "^1.0.1"
+        "find-root": "1.1.0",
+        "glob": "7.1.2",
+        "ignore": "3.3.10",
+        "pkg-config": "1.1.1",
+        "run-parallel": "1.1.9",
+        "uniq": "1.0.1"
       },
       "dependencies": {
         "glob": {
@@ -607,12 +607,12 @@
           "integrity": 
"sha512-MJTUg1kjuLeQCJ+ccE4Vpa6kKVXkPYJ2mOCQyUuKLcLQsdrMCpBPUi8qVE6+YuaJkozeA9NusTAw3hLr8Xe5EQ==",
           "dev": true,
           "requires": {
-            "fs.realpath": "^1.0.0",
-            "inflight": "^1.0.4",
-            "inherits": "2",
-            "minimatch": "^3.0.4",
-            "once": "^1.3.0",
-            "path-is-absolute": "^1.0.0"
+            "fs.realpath": "1.0.0",
+            "inflight": "1.0.6",
+            "inherits": "2.0.3",
+            "minimatch": "3.0.4",
+            "once": "1.4.0",
+            "path-is-absolute": "1.0.1"
           }
         }
       }
@@ -623,13 +623,13 @@
       "integrity": "sha1-wSyYHQZ4RshLyvhiz/kw2Qf/0ag=",
       "dev": true,
       "requires": {
-        "globby": "^5.0.0",
-        "is-path-cwd": "^1.0.0",
-        "is-path-in-cwd": "^1.0.0",
-        "object-assign": "^4.0.1",
-        "pify": "^2.0.0",
-        "pinkie-promise": "^2.0.0",
-        "rimraf": "^2.2.8"
+        "globby": "5.0.0",
+        "is-path-cwd": "1.0.0",
+        "is-path-in-cwd": "1.0.1",
+        "object-assign": "4.1.1",
+        "pify": "2.3.0",
+        "pinkie-promise": "2.0.1",
+        "rimraf": "2.6.2"
       }
     },
     "delayed-stream": {
@@ -643,7 +643,7 @@
       "integrity": 
"sha512-35mSku4ZXK0vfCuHEDAwt55dg2jNajHZ1odvF+8SSr82EsZY4QmXfuWso8oEd8zRhVObSN18aM0CjSdoBX7zIw==",
       "dev": true,
       "requires": {
-        "esutils": "^2.0.2"
+        "esutils": "2.0.2"
       }
     },
     "ecc-jsbn": {
@@ -652,8 +652,8 @@
       "integrity": "sha1-OoOpBOVDUyh4dMVkt1SThoSamMk=",
       "optional": true,
       "requires": {
-        "jsbn": "~0.1.0",
-        "safer-buffer": "^2.1.0"
+        "jsbn": "0.1.1",
+        "safer-buffer": "2.1.2"
       }
     },
     "error-ex": {
@@ -662,7 +662,7 @@
       "integrity": 
"sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g==",
       "dev": true,
       "requires": {
-        "is-arrayish": "^0.2.1"
+        "is-arrayish": "0.2.1"
       }
     },
     "errs": {
@@ -676,11 +676,11 @@
       "integrity": 
"sha512-C8Fx/0jFmV5IPoMOFPA9P9G5NtqW+4cOPit3MIuvR2t7Ag2K15EJTpxnHAYTzL+aYQJIESYeXZmDBfOBE1HcpA==",
       "dev": true,
       "requires": {
-        "es-to-primitive": "^1.1.1",
-        "function-bind": "^1.1.1",
-        "has": "^1.0.1",
-        "is-callable": "^1.1.3",
-        "is-regex": "^1.0.4"
+        "es-to-primitive": "1.1.1",
+        "function-bind": "1.1.1",
+        "has": "1.0.3",
+        "is-callable": "1.1.4",
+        "is-regex": "1.0.4"
       }
     },
     "es-to-primitive": {
@@ -689,9 +689,9 @@
       "integrity": "sha1-RTVSSKiJeQNLZ5Lhm7gfK3l13Q0=",
       "dev": true,
       "requires": {
-        "is-callable": "^1.1.1",
-        "is-date-object": "^1.0.1",
-        "is-symbol": "^1.0.1"
+        "is-callable": "1.1.4",
+        "is-date-object": "1.0.1",
+        "is-symbol": "1.0.1"
       }
     },
     "escape-string-regexp": {
@@ -706,11 +706,11 @@
       "integrity": "sha1-WltTr0aTEQvrsIZ6o0MN07cKEBg=",
       "dev": true,
       "requires": {
-        "esprima": "^2.7.1",
-        "estraverse": "^1.9.1",
-        "esutils": "^2.0.2",
-        "optionator": "^0.8.1",
-        "source-map": "~0.2.0"
+        "esprima": "2.7.3",
+        "estraverse": "1.9.3",
+        "esutils": "2.0.2",
+        "optionator": "0.8.2",
+        "source-map": "0.2.0"
       }
     },
     "eslint": {
@@ -719,43 +719,43 @@
       "integrity": 
"sha512-qy4i3wODqKMYfz9LUI8N2qYDkHkoieTbiHpMrYUI/WbjhXJQr7lI4VngixTgaG+yHX+NBCv7nW4hA0ShbvaNKw==",
       "dev": true,
       "requires": {
-        "ajv": "^5.3.0",
-        "babel-code-frame": "^6.22.0",
-        "chalk": "^2.1.0",
-        "concat-stream": "^1.6.0",
-        "cross-spawn": "^5.1.0",
-        "debug": "^3.1.0",
-        "doctrine": "^2.1.0",
-        "eslint-scope": "^3.7.1",
-        "eslint-visitor-keys": "^1.0.0",
-        "espree": "^3.5.2",
-        "esquery": "^1.0.0",
-        "esutils": "^2.0.2",
-        "file-entry-cache": "^2.0.0",
-        "functional-red-black-tree": "^1.0.1",
-        "glob": "^7.1.2",
-        "globals": "^11.0.1",
-        "ignore": "^3.3.3",
-        "imurmurhash": "^0.1.4",
-        "inquirer": "^3.0.6",
-        "is-resolvable": "^1.0.0",
-        "js-yaml": "^3.9.1",
-        "json-stable-stringify-without-jsonify": "^1.0.1",
-        "levn": "^0.3.0",
-        "lodash": "^4.17.4",
-        "minimatch": "^3.0.2",
-        "mkdirp": "^0.5.1",
-        "natural-compare": "^1.4.0",
-        "optionator": "^0.8.2",
-        "path-is-inside": "^1.0.2",
-        "pluralize": "^7.0.0",
-        "progress": "^2.0.0",
-        "require-uncached": "^1.0.3",
-        "semver": "^5.3.0",
-        "strip-ansi": "^4.0.0",
-        "strip-json-comments": "~2.0.1",
+        "ajv": "5.5.2",
+        "babel-code-frame": "6.26.0",
+        "chalk": "2.4.1",
+        "concat-stream": "1.6.2",
+        "cross-spawn": "5.1.0",
+        "debug": "3.1.0",
+        "doctrine": "2.1.0",
+        "eslint-scope": "3.7.3",
+        "eslint-visitor-keys": "1.0.0",
+        "espree": "3.5.4",
+        "esquery": "1.0.1",
+        "esutils": "2.0.2",
+        "file-entry-cache": "2.0.0",
+        "functional-red-black-tree": "1.0.1",
+        "glob": "7.1.2",
+        "globals": "11.7.0",
+        "ignore": "3.3.10",
+        "imurmurhash": "0.1.4",
+        "inquirer": "3.3.0",
+        "is-resolvable": "1.1.0",
+        "js-yaml": "3.12.0",
+        "json-stable-stringify-without-jsonify": "1.0.1",
+        "levn": "0.3.0",
+        "lodash": "4.17.10",
+        "minimatch": "3.0.4",
+        "mkdirp": "0.5.1",
+        "natural-compare": "1.4.0",
+        "optionator": "0.8.2",
+        "path-is-inside": "1.0.2",
+        "pluralize": "7.0.0",
+        "progress": "2.0.0",
+        "require-uncached": "1.0.3",
+        "semver": "5.5.0",
+        "strip-ansi": "4.0.0",
+        "strip-json-comments": "2.0.1",
         "table": "4.0.2",
-        "text-table": "~0.2.0"
+        "text-table": "0.2.0"
       },
       "dependencies": {
         "debug": {
@@ -773,12 +773,12 @@
           "integrity": 
"sha512-MJTUg1kjuLeQCJ+ccE4Vpa6kKVXkPYJ2mOCQyUuKLcLQsdrMCpBPUi8qVE6+YuaJkozeA9NusTAw3hLr8Xe5EQ==",
           "dev": true,
           "requires": {
-            "fs.realpath": "^1.0.0",
-            "inflight": "^1.0.4",
-            "inherits": "2",
-            "minimatch": "^3.0.4",
-            "once": "^1.3.0",
-            "path-is-absolute": "^1.0.0"
+            "fs.realpath": "1.0.0",
+            "inflight": "1.0.6",
+            "inherits": "2.0.3",
+            "minimatch": "3.0.4",
+            "once": "1.4.0",
+            "path-is-absolute": "1.0.1"
           }
         }
       }
@@ -801,8 +801,8 @@
       "integrity": 
"sha512-sfmTqJfPSizWu4aymbPr4Iidp5yKm8yDkHp+Ir3YiTHiiDfxh69mOUsmiqW6RZ9zRXFaF64GtYmN7e+8GHBv6Q==",
       "dev": true,
       "requires": {
-        "debug": "^2.6.9",
-        "resolve": "^1.5.0"
+        "debug": "2.6.9",
+        "resolve": "1.8.1"
       },
       "dependencies": {
         "resolve": {
@@ -811,7 +811,7 @@
           "integrity": 
"sha512-AicPrAC7Qu1JxPCZ9ZgCZlY35QgFnNqc+0LtbRNxnVw4TXvjQ72wnuL9JQcEBgXkI9JM8MsT9kaQoHcpCRJOYA==",
           "dev": true,
           "requires": {
-            "path-parse": "^1.0.5"
+            "path-parse": "1.0.6"
           }
         }
       }
@@ -822,8 +822,8 @@
       "integrity": "sha1-snA2LNiLGkitMIl2zn+lTphBF0Y=",
       "dev": true,
       "requires": {
-        "debug": "^2.6.8",
-        "pkg-dir": "^1.0.0"
+        "debug": "2.6.9",
+        "pkg-dir": "1.0.0"
       }
     },
     "eslint-plugin-import": {
@@ -832,16 +832,16 @@
       "integrity": "sha1-JgAu+/ylmJtyiKwEdQi9JPIXsWk=",
       "dev": true,
       "requires": {
-        "builtin-modules": "^1.1.1",
-        "contains-path": "^0.1.0",
-        "debug": "^2.6.8",
+        "builtin-modules": "1.1.1",
+        "contains-path": "0.1.0",
+        "debug": "2.6.9",
         "doctrine": "1.5.0",
-        "eslint-import-resolver-node": "^0.3.1",
-        "eslint-module-utils": "^2.1.1",
-        "has": "^1.0.1",
-        "lodash": "^4.17.4",
-        "minimatch": "^3.0.3",
-        "read-pkg-up": "^2.0.0"
+        "eslint-import-resolver-node": "0.3.2",
+        "eslint-module-utils": "2.2.0",
+        "has": "1.0.3",
+        "lodash": "4.17.10",
+        "minimatch": "3.0.4",
+        "read-pkg-up": "2.0.0"
       },
       "dependencies": {
         "doctrine": {
@@ -850,8 +850,8 @@
           "integrity": "sha1-N53Ocw9hZvds76TmcHoVmwLFpvo=",
           "dev": true,
           "requires": {
-            "esutils": "^2.0.2",
-            "isarray": "^1.0.0"
+            "esutils": "2.0.2",
+            "isarray": "1.0.0"
           }
         }
       }
@@ -862,10 +862,10 @@
       "integrity": 
"sha512-Q/Cc2sW1OAISDS+Ji6lZS2KV4b7ueA/WydVWd1BECTQwVvfQy5JAi3glhINoKzoMnfnuRgNP+ZWKrGAbp3QDxw==",
       "dev": true,
       "requires": {
-        "ignore": "^3.3.6",
-        "minimatch": "^3.0.4",
-        "resolve": "^1.3.3",
-        "semver": "^5.4.1"
+        "ignore": "3.3.10",
+        "minimatch": "3.0.4",
+        "resolve": "1.8.1",
+        "semver": "5.5.0"
       },
       "dependencies": {
         "resolve": {
@@ -874,7 +874,7 @@
           "integrity": 
"sha512-AicPrAC7Qu1JxPCZ9ZgCZlY35QgFnNqc+0LtbRNxnVw4TXvjQ72wnuL9JQcEBgXkI9JM8MsT9kaQoHcpCRJOYA==",
           "dev": true,
           "requires": {
-            "path-parse": "^1.0.5"
+            "path-parse": "1.0.6"
           }
         }
       }
@@ -891,10 +891,10 @@
       "integrity": 
"sha512-KC7Snr4YsWZD5flu6A5c0AcIZidzW3Exbqp7OT67OaD2AppJtlBr/GuPrW/vaQM/yfZotEvKAdrxrO+v8vwYJA==",
       "dev": true,
       "requires": {
-        "doctrine": "^2.0.2",
-        "has": "^1.0.1",
-        "jsx-ast-utils": "^2.0.1",
-        "prop-types": "^15.6.0"
+        "doctrine": "2.1.0",
+        "has": "1.0.3",
+        "jsx-ast-utils": "2.0.1",
+        "prop-types": "15.6.2"
       }
     },
     "eslint-plugin-standard": {
@@ -909,8 +909,8 @@
       "integrity": 
"sha512-W+B0SvF4gamyCTmUc+uITPY0989iXVfKvhwtmJocTaYoc/3khEHmEmvfY/Gn9HA9VV75jrQECsHizkNw1b68FA==",
       "dev": true,
       "requires": {
-        "esrecurse": "^4.1.0",
-        "estraverse": "^4.1.1"
+        "esrecurse": "4.2.1",
+        "estraverse": "4.2.0"
       },
       "dependencies": {
         "estraverse": {
@@ -933,8 +933,8 @@
       "integrity": 
"sha512-yAcIQxtmMiB/jL32dzEp2enBeidsB7xWPLNiw3IIkpVds1P+h7qF9YwJq1yUNzp2OKXgAprs4F61ih66UsoD1A==",
       "dev": true,
       "requires": {
-        "acorn": "^5.5.0",
-        "acorn-jsx": "^3.0.0"
+        "acorn": "5.7.1",
+        "acorn-jsx": "3.0.1"
       }
     },
     "esprima": {
@@ -949,7 +949,7 @@
       "integrity": 
"sha512-SmiyZ5zIWH9VM+SRUReLS5Q8a7GxtRdxEBVZpm98rJM7Sb+A9DVCndXfkeFUd3byderg+EbDkfnevfCwynWaNA==",
       "dev": true,
       "requires": {
-        "estraverse": "^4.0.0"
+        "estraverse": "4.2.0"
       },
       "dependencies": {
         "estraverse": {
@@ -966,7 +966,7 @@
       "integrity": 
"sha512-64RBB++fIOAXPw3P9cy89qfMlvZEXZkqqJkjqqXIvzP5ezRZjW+lPWjw35UX/3EhUPFYbg5ER4JYgDw4007/DQ==",
       "dev": true,
       "requires": {
-        "estraverse": "^4.1.0"
+        "estraverse": "4.2.0"
       },
       "dependencies": {
         "estraverse": {
@@ -1000,9 +1000,9 @@
       "integrity": 
"sha512-bSn6gvGxKt+b7+6TKEv1ZycHleA7aHhRHyAqJyp5pbUFuYYNIzpZnQDk7AsYckyWdEnTeAnay0aCy2aV6iTk9A==",
       "dev": true,
       "requires": {
-        "chardet": "^0.4.0",
-        "iconv-lite": "^0.4.17",
-        "tmp": "^0.0.33"
+        "chardet": "0.4.2",
+        "iconv-lite": "0.4.23",
+        "tmp": "0.0.33"
       }
     },
     "extsprintf": {
@@ -1032,7 +1032,7 @@
       "integrity": "sha1-OrGi0qYsi/tDGgyUy3l6L84nyWI=",
       "dev": true,
       "requires": {
-        "escape-string-regexp": "^1.0.5"
+        "escape-string-regexp": "1.0.5"
       }
     },
     "file-entry-cache": {
@@ -1041,8 +1041,8 @@
       "integrity": "sha1-w5KZDD5oR4PYOLjISkXYoEhFg2E=",
       "dev": true,
       "requires": {
-        "flat-cache": "^1.2.1",
-        "object-assign": "^4.0.1"
+        "flat-cache": "1.3.0",
+        "object-assign": "4.1.1"
       }
     },
     "find-root": {
@@ -1057,8 +1057,8 @@
       "integrity": "sha1-ay6YIrGizgpgq2TWEOzK1TyyTQ8=",
       "dev": true,
       "requires": {
-        "path-exists": "^2.0.0",
-        "pinkie-promise": "^2.0.0"
+        "path-exists": "2.1.0",
+        "pinkie-promise": "2.0.1"
       }
     },
     "flat-cache": {
@@ -1067,10 +1067,10 @@
       "integrity": "sha1-0wMLMrOBVPTjt+nHCfSQ9++XxIE=",
       "dev": true,
       "requires": {
-        "circular-json": "^0.3.1",
-        "del": "^2.0.2",
-        "graceful-fs": "^4.1.2",
-        "write": "^0.2.1"
+        "circular-json": "0.3.3",
+        "del": "2.2.2",
+        "graceful-fs": "4.1.11",
+        "write": "0.2.1"
       }
     },
     "for-each": {
@@ -1079,7 +1079,7 @@
       "integrity": 
"sha512-jqYfLp7mo9vIyQf8ykW2v7A+2N4QjeCeI5+Dz9XraiO1ign81wjiH7Fb9vSOWvQfNtmSa4H2RoQTrrXivdUZmw==",
       "dev": true,
       "requires": {
-        "is-callable": "^1.1.3"
+        "is-callable": "1.1.4"
       }
     },
     "foreach": {
@@ -1098,9 +1098,9 @@
       "resolved": "https://registry.npmjs.org/form-data/-/form-data-2.3.2.tgz";,
       "integrity": "sha1-SXBJi+YEwgwAXU9cI67NIda0kJk=",
       "requires": {
-        "asynckit": "^0.4.0",
+        "asynckit": "0.4.0",
         "combined-stream": "1.0.6",
-        "mime-types": "^2.1.12"
+        "mime-types": "2.1.19"
       }
     },
     "fs.realpath": {
@@ -1138,7 +1138,7 @@
       "resolved": "https://registry.npmjs.org/getpass/-/getpass-0.1.7.tgz";,
       "integrity": "sha1-Xv+OPmhNVprkyysSgmBOi6YhSfo=",
       "requires": {
-        "assert-plus": "^1.0.0"
+        "assert-plus": "1.0.0"
       }
     },
     "glob": {
@@ -1147,11 +1147,11 @@
       "integrity": "sha1-G8k2ueAvSmA/zCIuz3Yz0wuLk7E=",
       "dev": true,
       "requires": {
-        "inflight": "^1.0.4",
-        "inherits": "2",
-        "minimatch": "2 || 3",
-        "once": "^1.3.0",
-        "path-is-absolute": "^1.0.0"
+        "inflight": "1.0.6",
+        "inherits": "2.0.3",
+        "minimatch": "3.0.4",
+        "once": "1.4.0",
+        "path-is-absolute": "1.0.1"
       }
     },
     "globals": {
@@ -1166,12 +1166,12 @@
       "integrity": "sha1-69hGZ8oNuzMLmbz8aOrCvFQ3Dg0=",
       "dev": true,
       "requires": {
-        "array-union": "^1.0.1",
-        "arrify": "^1.0.0",
-        "glob": "^7.0.3",
-        "object-assign": "^4.0.1",
-        "pify": "^2.0.0",
-        "pinkie-promise": "^2.0.0"
+        "array-union": "1.0.2",
+        "arrify": "1.0.1",
+        "glob": "7.1.2",
+        "object-assign": "4.1.1",
+        "pify": "2.3.0",
+        "pinkie-promise": "2.0.1"
       },
       "dependencies": {
         "glob": {
@@ -1180,12 +1180,12 @@
           "integrity": 
"sha512-MJTUg1kjuLeQCJ+ccE4Vpa6kKVXkPYJ2mOCQyUuKLcLQsdrMCpBPUi8qVE6+YuaJkozeA9NusTAw3hLr8Xe5EQ==",
           "dev": true,
           "requires": {
-            "fs.realpath": "^1.0.0",
-            "inflight": "^1.0.4",
-            "inherits": "2",
-            "minimatch": "^3.0.4",
-            "once": "^1.3.0",
-            "path-is-absolute": "^1.0.0"
+            "fs.realpath": "1.0.0",
+            "inflight": "1.0.6",
+            "inherits": "2.0.3",
+            "minimatch": "3.0.4",
+            "once": "1.4.0",
+            "path-is-absolute": "1.0.1"
           }
         }
       }
@@ -1202,10 +1202,10 @@
       "integrity": "sha1-Ywo13+ApS8KB7a5v/F0yn8eYLcw=",
       "dev": true,
       "requires": {
-        "async": "^1.4.0",
-        "optimist": "^0.6.1",
-        "source-map": "^0.4.4",
-        "uglify-js": "^2.6"
+        "async": "1.5.2",
+        "optimist": "0.6.1",
+        "source-map": "0.4.4",
+        "uglify-js": "2.8.29"
       },
       "dependencies": {
         "async": {
@@ -1220,7 +1220,7 @@
           "integrity": "sha1-66T12pwNyZneaAMti092FzZSA2s=",
           "dev": true,
           "requires": {
-            "amdefine": ">=0.0.4"
+            "amdefine": "1.0.1"
           }
         }
       }
@@ -1235,8 +1235,8 @@
       "resolved": 
"https://registry.npmjs.org/har-validator/-/har-validator-5.1.0.tgz";,
       "integrity": 
"sha512-+qnmNjI4OfH2ipQ9VQOw23bBd/ibtfbVdK2fYbY4acTDqKTW/YDp9McimZdDbG8iV9fZizUqQMD5xvriB146TA==",
       "requires": {
-        "ajv": "^5.3.0",
-        "har-schema": "^2.0.0"
+        "ajv": "5.5.2",
+        "har-schema": "2.0.0"
       }
     },
     "has": {
@@ -1245,7 +1245,7 @@
       "integrity": 
"sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==",
       "dev": true,
       "requires": {
-        "function-bind": "^1.1.1"
+        "function-bind": "1.1.1"
       }
     },
     "has-ansi": {
@@ -1254,7 +1254,7 @@
       "integrity": "sha1-NPUEnOHs3ysGSa8+8k5F7TVBbZE=",
       "dev": true,
       "requires": {
-        "ansi-regex": "^2.0.0"
+        "ansi-regex": "2.1.1"
       }
     },
     "has-flag": {
@@ -1274,9 +1274,9 @@
       "resolved": 
"https://registry.npmjs.org/http-signature/-/http-signature-1.2.0.tgz";,
       "integrity": "sha1-muzZJRFHcvPZW2WmCruPfBj7rOE=",
       "requires": {
-        "assert-plus": "^1.0.0",
-        "jsprim": "^1.2.2",
-        "sshpk": "^1.7.0"
+        "assert-plus": "1.0.0",
+        "jsprim": "1.4.1",
+        "sshpk": "1.14.2"
       }
     },
     "iconv-lite": {
@@ -1285,7 +1285,7 @@
       "integrity": 
"sha512-neyTUVFtahjf0mB3dZT77u+8O0QB89jFdnBkd5P1JgYPbPaia3gXXOVL2fq8VyU2gMMD7SaN7QukTB/pmXYvDA==",
       "dev": true,
       "requires": {
-        "safer-buffer": ">= 2.1.2 < 3"
+        "safer-buffer": "2.1.2"
       }
     },
     "ignore": {
@@ -1306,8 +1306,8 @@
       "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=",
       "dev": true,
       "requires": {
-        "once": "^1.3.0",
-        "wrappy": "1"
+        "once": "1.4.0",
+        "wrappy": "1.0.2"
       }
     },
     "inherits": {
@@ -1322,20 +1322,20 @@
       "integrity": 
"sha512-h+xtnyk4EwKvFWHrUYsWErEVR+igKtLdchu+o0Z1RL7VU/jVMFbYir2bp6bAj8efFNxWqHX0dIss6fJQ+/+qeQ==",
       "dev": true,
       "requires": {
-        "ansi-escapes": "^3.0.0",
-        "chalk": "^2.0.0",
-        "cli-cursor": "^2.1.0",
-        "cli-width": "^2.0.0",
-        "external-editor": "^2.0.4",
-        "figures": "^2.0.0",
-        "lodash": "^4.3.0",
+        "ansi-escapes": "3.1.0",
+        "chalk": "2.4.1",
+        "cli-cursor": "2.1.0",
+        "cli-width": "2.2.0",
+        "external-editor": "2.2.0",
+        "figures": "2.0.0",
+        "lodash": "4.17.10",
         "mute-stream": "0.0.7",
-        "run-async": "^2.2.0",
-        "rx-lite": "^4.0.8",
-        "rx-lite-aggregates": "^4.0.8",
-        "string-width": "^2.1.0",
-        "strip-ansi": "^4.0.0",
-        "through": "^2.3.6"
+        "run-async": "2.3.0",
+        "rx-lite": "4.0.8",
+        "rx-lite-aggregates": "4.0.8",
+        "string-width": "2.1.1",
+        "strip-ansi": "4.0.0",
+        "through": "2.3.8"
       }
     },
     "is-arrayish": {
@@ -1356,7 +1356,7 @@
       "integrity": "sha1-VAVy0096wxGfj3bDDLwbHgN6/74=",
       "dev": true,
       "requires": {
-        "builtin-modules": "^1.0.0"
+        "builtin-modules": "1.1.1"
       }
     },
     "is-callable": {
@@ -1389,7 +1389,7 @@
       "integrity": 
"sha512-FjV1RTW48E7CWM7eE/J2NJvAEEVektecDBVBE5Hh3nM1Jd0kvhHtX68Pr3xsDf857xt3Y4AkwVULK1Vku62aaQ==",
       "dev": true,
       "requires": {
-        "is-path-inside": "^1.0.0"
+        "is-path-inside": "1.0.1"
       }
     },
     "is-path-inside": {
@@ -1398,7 +1398,7 @@
       "integrity": "sha1-jvW33lBDej/cprToZe96pVy0gDY=",
       "dev": true,
       "requires": {
-        "path-is-inside": "^1.0.1"
+        "path-is-inside": "1.0.2"
       }
     },
     "is-promise": {
@@ -1413,7 +1413,7 @@
       "integrity": "sha1-VRdIm1RwkbCTDglWVM7SXul+lJE=",
       "dev": true,
       "requires": {
-        "has": "^1.0.1"
+        "has": "1.0.3"
       }
     },
     "is-resolvable": {
@@ -1456,20 +1456,20 @@
       "integrity": "sha1-ZcfXPUxNqE1POsMQuRj7C4Azczs=",
       "dev": true,
       "requires": {
-        "abbrev": "1.0.x",
-        "async": "1.x",
-        "escodegen": "1.8.x",
-        "esprima": "2.7.x",
-        "glob": "^5.0.15",
-        "handlebars": "^4.0.1",
-        "js-yaml": "3.x",
-        "mkdirp": "0.5.x",
-        "nopt": "3.x",
-        "once": "1.x",
-        "resolve": "1.1.x",
-        "supports-color": "^3.1.0",
-        "which": "^1.1.1",
-        "wordwrap": "^1.0.0"
+        "abbrev": "1.0.9",
+        "async": "1.5.2",
+        "escodegen": "1.8.1",
+        "esprima": "2.7.3",
+        "glob": "5.0.15",
+        "handlebars": "4.0.11",
+        "js-yaml": "3.12.0",
+        "mkdirp": "0.5.1",
+        "nopt": "3.0.6",
+        "once": "1.4.0",
+        "resolve": "1.1.7",
+        "supports-color": "3.2.3",
+        "which": "1.3.1",
+        "wordwrap": "1.0.0"
       },
       "dependencies": {
         "async": {
@@ -1492,8 +1492,8 @@
       "integrity": 
"sha512-PIt2cnwmPfL4hKNwqeiuz4bKfnzHTBv6HyVgjahA6mPLwPDzjDWrplJBMjHUFxku/N3FlmrbyPclad+I+4mJ3A==",
       "dev": true,
       "requires": {
-        "argparse": "^1.0.7",
-        "esprima": "^4.0.0"
+        "argparse": "1.0.10",
+        "esprima": "4.0.1"
       },
       "dependencies": {
         "esprima": {
@@ -1554,7 +1554,7 @@
       "integrity": "sha1-6AGxs5mF4g//yHtA43SAgOLcrH8=",
       "dev": true,
       "requires": {
-        "array-includes": "^3.0.3"
+        "array-includes": "3.0.3"
       }
     },
     "kind-of": {
@@ -1563,7 +1563,7 @@
       "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=",
       "dev": true,
       "requires": {
-        "is-buffer": "^1.1.5"
+        "is-buffer": "1.1.6"
       }
     },
     "lazy-cache": {
@@ -1579,8 +1579,8 @@
       "integrity": "sha1-OwmSTt+fCDwEkP3UwLxEIeBHZO4=",
       "dev": true,
       "requires": {
-        "prelude-ls": "~1.1.2",
-        "type-check": "~0.3.2"
+        "prelude-ls": "1.1.2",
+        "type-check": "0.3.2"
       }
     },
     "load-json-file": {
@@ -1589,10 +1589,10 @@
       "integrity": "sha1-eUfkIUmvgNaWy/eXvKq8/h/inKg=",
       "dev": true,
       "requires": {
-        "graceful-fs": "^4.1.2",
-        "parse-json": "^2.2.0",
-        "pify": "^2.0.0",
-        "strip-bom": "^3.0.0"
+        "graceful-fs": "4.1.11",
+        "parse-json": "2.2.0",
+        "pify": "2.3.0",
+        "strip-bom": "3.0.0"
       }
     },
     "locate-path": {
@@ -1601,8 +1601,8 @@
       "integrity": "sha1-K1aLJl7slExtnA3pw9u7ygNUzY4=",
       "dev": true,
       "requires": {
-        "p-locate": "^2.0.0",
-        "path-exists": "^3.0.0"
+        "p-locate": "2.0.0",
+        "path-exists": "3.0.0"
       },
       "dependencies": {
         "path-exists": {
@@ -1636,7 +1636,7 @@
       "integrity": 
"sha512-lyuxPGr/Wfhrlem2CL/UcnUc1zcqKAImBDzukY7Y5F/yQiNdko6+fRLevlw1HgMySw7f611UIY408EtxRSoK3Q==",
       "dev": true,
       "requires": {
-        "js-tokens": "^3.0.0 || ^4.0.0"
+        "js-tokens": "3.0.2"
       }
     },
     "lru-cache": {
@@ -1645,8 +1645,8 @@
       "integrity": 
"sha512-fFEhvcgzuIoJVUF8fYr5KR0YqxD238zgObTps31YdADwPPAp82a4M8TrckkWyx7ekNlf9aBcVn81cFwwXngrJA==",
       "dev": true,
       "requires": {
-        "pseudomap": "^1.0.2",
-        "yallist": "^2.1.2"
+        "pseudomap": "1.0.2",
+        "yallist": "2.1.2"
       }
     },
     "mime-db": {
@@ -1659,7 +1659,7 @@
       "resolved": 
"https://registry.npmjs.org/mime-types/-/mime-types-2.1.19.tgz";,
       "integrity": 
"sha512-P1tKYHVSZ6uFo26mtnve4HQFE3koh1UWVkp8YUC+ESBHe945xWSoXuHHiGarDqcEZ+whpCDnlNw5LON0kLo+sw==",
       "requires": {
-        "mime-db": "~1.35.0"
+        "mime-db": "1.35.0"
       }
     },
     "mimic-fn": {
@@ -1674,7 +1674,7 @@
       "integrity": 
"sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==",
       "dev": true,
       "requires": {
-        "brace-expansion": "^1.1.7"
+        "brace-expansion": "1.1.11"
       }
     },
     "minimist": {
@@ -1723,15 +1723,15 @@
       "integrity": 
"sha512-EDgl/WgNQ0C1BZZlASOQkQdE6tAWXJi8QQlugqzN64JJkvZ7ILijZuG24r4vCC7yOfnm6HKpne5AGExLGCeBWg==",
       "dev": true,
       "requires": {
-        "chai": "^4.1.2",
-        "debug": "^3.1.0",
-        "deep-equal": "^1.0.0",
-        "json-stringify-safe": "^5.0.1",
-        "lodash": "^4.17.5",
-        "mkdirp": "^0.5.0",
-        "propagate": "^1.0.0",
-        "qs": "^6.5.1",
-        "semver": "^5.5.0"
+        "chai": "4.1.2",
+        "debug": "3.1.0",
+        "deep-equal": "1.0.1",
+        "json-stringify-safe": "5.0.1",
+        "lodash": "4.17.10",
+        "mkdirp": "0.5.1",
+        "propagate": "1.0.0",
+        "qs": "6.5.2",
+        "semver": "5.5.0"
       },
       "dependencies": {
         "debug": {
@@ -1751,7 +1751,7 @@
       "integrity": "sha1-xkZdvwirzU2zWTF/eaxopkayj/k=",
       "dev": true,
       "requires": {
-        "abbrev": "1"
+        "abbrev": "1.0.9"
       }
     },
     "normalize-package-data": {
@@ -1760,10 +1760,10 @@
       "integrity": 
"sha512-9jjUFbTPfEy3R/ad/2oNbKtW9Hgovl5O1FvFWKkKblNXoN/Oou6+9+KKohPK13Yc3/TyunyWhJp6gvRNR/PPAw==",
       "dev": true,
       "requires": {
-        "hosted-git-info": "^2.1.4",
-        "is-builtin-module": "^1.0.0",
-        "semver": "2 || 3 || 4 || 5",
-        "validate-npm-package-license": "^3.0.1"
+        "hosted-git-info": "2.7.1",
+        "is-builtin-module": "1.0.0",
+        "semver": "5.5.0",
+        "validate-npm-package-license": "3.0.4"
       }
     },
     "oauth-sign": {
@@ -1795,7 +1795,7 @@
       "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=",
       "dev": true,
       "requires": {
-        "wrappy": "1"
+        "wrappy": "1.0.2"
       }
     },
     "onetime": {
@@ -1804,7 +1804,7 @@
       "integrity": "sha1-BnQoIw/WdEOyeUsiu6UotoZ5YtQ=",
       "dev": true,
       "requires": {
-        "mimic-fn": "^1.0.0"
+        "mimic-fn": "1.2.0"
       }
     },
     "optimist": {
@@ -1813,8 +1813,8 @@
       "integrity": "sha1-2j6nRob6IaGaERwybpDrFaAZZoY=",
       "dev": true,
       "requires": {
-        "minimist": "~0.0.1",
-        "wordwrap": "~0.0.2"
+        "minimist": "0.0.10",
+        "wordwrap": "0.0.3"
       },
       "dependencies": {
         "wordwrap": {
@@ -1831,12 +1831,12 @@
       "integrity": "sha1-NkxeQJ0/TWMB1sC0wFu6UBgK62Q=",
       "dev": true,
       "requires": {
-        "deep-is": "~0.1.3",
-        "fast-levenshtein": "~2.0.4",
-        "levn": "~0.3.0",
-        "prelude-ls": "~1.1.2",
-        "type-check": "~0.3.2",
-        "wordwrap": "~1.0.0"
+        "deep-is": "0.1.3",
+        "fast-levenshtein": "2.0.6",
+        "levn": "0.3.0",
+        "prelude-ls": "1.1.2",
+        "type-check": "0.3.2",
+        "wordwrap": "1.0.0"
       }
     },
     "os-tmpdir": {
@@ -1851,7 +1851,7 @@
       "integrity": 
"sha512-vvcXsLAJ9Dr5rQOPk7toZQZJApBl2K4J6dANSsEuh6QI41JYcsS/qhTGa9ErIUUgK3WNQoJYvylxvjqmiqEA9Q==",
       "dev": true,
       "requires": {
-        "p-try": "^1.0.0"
+        "p-try": "1.0.0"
       }
     },
     "p-locate": {
@@ -1860,7 +1860,7 @@
       "integrity": "sha1-IKAQOyIqcMj9OcwuWAaA893l7EM=",
       "dev": true,
       "requires": {
-        "p-limit": "^1.1.0"
+        "p-limit": "1.3.0"
       }
     },
     "p-try": {
@@ -1875,7 +1875,7 @@
       "integrity": "sha1-9ID0BDTvgHQfhGkJn43qGPVaTck=",
       "dev": true,
       "requires": {
-        "error-ex": "^1.2.0"
+        "error-ex": "1.3.2"
       }
     },
     "path-exists": {
@@ -1884,7 +1884,7 @@
       "integrity": "sha1-D+tsZPD8UY2adU3V77YscCJ2H0s=",
       "dev": true,
       "requires": {
-        "pinkie-promise": "^2.0.0"
+        "pinkie-promise": "2.0.1"
       }
     },
     "path-is-absolute": {
@@ -1911,7 +1911,7 @@
       "integrity": "sha1-8BLMuEFbcJb8LaoQVMPXI4lZTHM=",
       "dev": true,
       "requires": {
-        "pify": "^2.0.0"
+        "pify": "2.3.0"
       }
     },
     "pathval": {
@@ -1943,7 +1943,7 @@
       "integrity": "sha1-ITXW36ejWMBprJsXh3YogihFD/o=",
       "dev": true,
       "requires": {
-        "pinkie": "^2.0.0"
+        "pinkie": "2.0.4"
       }
     },
     "pkg-conf": {
@@ -1952,8 +1952,8 @@
       "integrity": "sha1-ISZRTKbyq/69FoWW3xi6V4Z/AFg=",
       "dev": true,
       "requires": {
-        "find-up": "^2.0.0",
-        "load-json-file": "^4.0.0"
+        "find-up": "2.1.0",
+        "load-json-file": "4.0.0"
       },
       "dependencies": {
         "find-up": {
@@ -1962,7 +1962,7 @@
           "integrity": "sha1-RdG35QbHF93UgndaK3eSCjwMV6c=",
           "dev": true,
           "requires": {
-            "locate-path": "^2.0.0"
+            "locate-path": "2.0.0"
           }
         },
         "load-json-file": {
@@ -1971,10 +1971,10 @@
           "integrity": "sha1-L19Fq5HjMhYjT9U62rZo607AmTs=",
           "dev": true,
           "requires": {
-            "graceful-fs": "^4.1.2",
-            "parse-json": "^4.0.0",
-            "pify": "^3.0.0",
-            "strip-bom": "^3.0.0"
+            "graceful-fs": "4.1.11",
+            "parse-json": "4.0.0",
+            "pify": "3.0.0",
+            "strip-bom": "3.0.0"
           }
         },
         "parse-json": {
@@ -1983,8 +1983,8 @@
           "integrity": "sha1-vjX1Qlvh9/bHRxhPmKeIy5lHfuA=",
           "dev": true,
           "requires": {
-            "error-ex": "^1.3.1",
-            "json-parse-better-errors": "^1.0.1"
+            "error-ex": "1.3.2",
+            "json-parse-better-errors": "1.0.2"
           }
         },
         "pify": {
@@ -2001,9 +2001,9 @@
       "integrity": "sha1-VX7yLXPaPIg3EHdmxS6tq94pj+Q=",
       "dev": true,
       "requires": {
-        "debug-log": "^1.0.0",
-        "find-root": "^1.0.0",
-        "xtend": "^4.0.1"
+        "debug-log": "1.0.1",
+        "find-root": "1.1.0",
+        "xtend": "4.0.1"
       }
     },
     "pkg-dir": {
@@ -2012,7 +2012,7 @@
       "integrity": "sha1-ektQio1bstYp1EcFb/TpyTFM89Q=",
       "dev": true,
       "requires": {
-        "find-up": "^1.0.0"
+        "find-up": "1.1.2"
       }
     },
     "pluralize": {
@@ -2045,8 +2045,8 @@
       "integrity": 
"sha512-3pboPvLiWD7dkI3qf3KbUe6hKFKa52w+AE0VCqECtf+QHAKgOL37tTaNCnuX1nAAQ4ZhyP+kYVKf8rLmJ/feDQ==",
       "dev": true,
       "requires": {
-        "loose-envify": "^1.3.1",
-        "object-assign": "^4.1.1"
+        "loose-envify": "1.4.0",
+        "object-assign": "4.1.1"
       }
     },
     "propagate": {
@@ -2082,9 +2082,9 @@
       "integrity": "sha1-jvHAYjxqbbDcZxPEv6xGMysjaPg=",
       "dev": true,
       "requires": {
-        "load-json-file": "^2.0.0",
-        "normalize-package-data": "^2.3.2",
-        "path-type": "^2.0.0"
+        "load-json-file": "2.0.0",
+        "normalize-package-data": "2.4.0",
+        "path-type": "2.0.0"
       }
     },
     "read-pkg-up": {
@@ -2093,8 +2093,8 @@
       "integrity": "sha1-a3KoBImE4MQeeVEP1en6mbO1Sb4=",
       "dev": true,
       "requires": {
-        "find-up": "^2.0.0",
-        "read-pkg": "^2.0.0"
+        "find-up": "2.1.0",
+        "read-pkg": "2.0.0"
       },
       "dependencies": {
         "find-up": {
@@ -2103,7 +2103,7 @@
           "integrity": "sha1-RdG35QbHF93UgndaK3eSCjwMV6c=",
           "dev": true,
           "requires": {
-            "locate-path": "^2.0.0"
+            "locate-path": "2.0.0"
           }
         }
       }
@@ -2114,13 +2114,13 @@
       "integrity": 
"sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw==",
       "dev": true,
       "requires": {
-        "core-util-is": "~1.0.0",
-        "inherits": "~2.0.3",
-        "isarray": "~1.0.0",
-        "process-nextick-args": "~2.0.0",
-        "safe-buffer": "~5.1.1",
-        "string_decoder": "~1.1.1",
-        "util-deprecate": "~1.0.1"
+        "core-util-is": "1.0.2",
+        "inherits": "2.0.3",
+        "isarray": "1.0.0",
+        "process-nextick-args": "2.0.0",
+        "safe-buffer": "5.1.2",
+        "string_decoder": "1.1.1",
+        "util-deprecate": "1.0.2"
       }
     },
     "repeat-string": {
@@ -2134,26 +2134,26 @@
       "resolved": "https://registry.npmjs.org/request/-/request-2.88.0.tgz";,
       "integrity": 
"sha512-NAqBSrijGLZdM0WZNsInLJpkJokL72XYjUpnB0iwsRgxh7dB6COrHnTBNwN0E+lHDAJzu7kLAkDeY08z2/A0hg==",
       "requires": {
-        "aws-sign2": "~0.7.0",
-        "aws4": "^1.8.0",
-        "caseless": "~0.12.0",
-        "combined-stream": "~1.0.6",
-        "extend": "~3.0.2",
-        "forever-agent": "~0.6.1",
-        "form-data": "~2.3.2",
-        "har-validator": "~5.1.0",
-        "http-signature": "~1.2.0",
-        "is-typedarray": "~1.0.0",
-        "isstream": "~0.1.2",
-        "json-stringify-safe": "~5.0.1",
-        "mime-types": "~2.1.19",
-        "oauth-sign": "~0.9.0",
-        "performance-now": "^2.1.0",
-        "qs": "~6.5.2",
-        "safe-buffer": "^5.1.2",
-        "tough-cookie": "~2.4.3",
-        "tunnel-agent": "^0.6.0",
-        "uuid": "^3.3.2"
+        "aws-sign2": "0.7.0",
+        "aws4": "1.8.0",
+        "caseless": "0.12.0",
+        "combined-stream": "1.0.6",
+        "extend": "3.0.2",
+        "forever-agent": "0.6.1",
+        "form-data": "2.3.2",
+        "har-validator": "5.1.0",
+        "http-signature": "1.2.0",
+        "is-typedarray": "1.0.0",
+        "isstream": "0.1.2",
+        "json-stringify-safe": "5.0.1",
+        "mime-types": "2.1.19",
+        "oauth-sign": "0.9.0",
+        "performance-now": "2.1.0",
+        "qs": "6.5.2",
+        "safe-buffer": "5.1.2",
+        "tough-cookie": "2.4.3",
+        "tunnel-agent": "0.6.0",
+        "uuid": "3.3.2"
       }
     },
     "require-uncached": {
@@ -2162,8 +2162,8 @@
       "integrity": "sha1-Tg1W1slmL9MeQwEcS5WqSZVUIdM=",
       "dev": true,
       "requires": {
-        "caller-path": "^0.1.0",
-        "resolve-from": "^1.0.0"
+        "caller-path": "0.1.0",
+        "resolve-from": "1.0.1"
       }
     },
     "resolve": {
@@ -2184,8 +2184,8 @@
       "integrity": "sha1-n37ih/gv0ybU/RYpI9YhKe7g368=",
       "dev": true,
       "requires": {
-        "onetime": "^2.0.0",
-        "signal-exit": "^3.0.2"
+        "onetime": "2.0.1",
+        "signal-exit": "3.0.2"
       }
     },
     "resumer": {
@@ -2194,7 +2194,7 @@
       "integrity": "sha1-8ej0YeQGS6Oegq883CqMiT0HZ1k=",
       "dev": true,
       "requires": {
-        "through": "~2.3.4"
+        "through": "2.3.8"
       }
     },
     "right-align": {
@@ -2204,7 +2204,7 @@
       "dev": true,
       "optional": true,
       "requires": {
-        "align-text": "^0.1.1"
+        "align-text": "0.1.4"
       }
     },
     "rimraf": {
@@ -2213,7 +2213,7 @@
       "integrity": 
"sha512-lreewLK/BlghmxtfH36YYVg1i8IAce4TI7oao75I1g245+6BctqTVQiBP3YUJ9C6DQOXJmkYR9X9fCLtCOJc5w==",
       "dev": true,
       "requires": {
-        "glob": "^7.0.5"
+        "glob": "7.1.2"
       },
       "dependencies": {
         "glob": {
@@ -2222,12 +2222,12 @@
           "integrity": 
"sha512-MJTUg1kjuLeQCJ+ccE4Vpa6kKVXkPYJ2mOCQyUuKLcLQsdrMCpBPUi8qVE6+YuaJkozeA9NusTAw3hLr8Xe5EQ==",
           "dev": true,
           "requires": {
-            "fs.realpath": "^1.0.0",
-            "inflight": "^1.0.4",
-            "inherits": "2",
-            "minimatch": "^3.0.4",
-            "once": "^1.3.0",
-            "path-is-absolute": "^1.0.0"
+            "fs.realpath": "1.0.0",
+            "inflight": "1.0.6",
+            "inherits": "2.0.3",
+            "minimatch": "3.0.4",
+            "once": "1.4.0",
+            "path-is-absolute": "1.0.1"
           }
         }
       }
@@ -2238,7 +2238,7 @@
       "integrity": "sha1-A3GrSuC91yDUFm19/aZP96RFpsA=",
       "dev": true,
       "requires": {
-        "is-promise": "^2.1.0"
+        "is-promise": "2.1.0"
       }
     },
     "run-parallel": {
@@ -2259,7 +2259,7 @@
       "integrity": "sha1-dTuHqJoRyVRnxKwWJsTvxOBcZ74=",
       "dev": true,
       "requires": {
-        "rx-lite": "*"
+        "rx-lite": "4.0.8"
       }
     },
     "safe-buffer": {
@@ -2284,7 +2284,7 @@
       "integrity": "sha1-RKrGW2lbAzmJaMOfNj/uXer98eo=",
       "dev": true,
       "requires": {
-        "shebang-regex": "^1.0.0"
+        "shebang-regex": "1.0.0"
       }
     },
     "shebang-regex": {
@@ -2305,7 +2305,7 @@
       "integrity": 
"sha512-POqxBK6Lb3q6s047D/XsDVNPnF9Dl8JSaqe9h9lURl0OdNqy/ujDrOiIHtsqXMGbWWTIomRzAMaTyawAU//Reg==",
       "dev": true,
       "requires": {
-        "is-fullwidth-code-point": "^2.0.0"
+        "is-fullwidth-code-point": "2.0.0"
       }
     },
     "source-map": {
@@ -2315,7 +2315,7 @@
       "dev": true,
       "optional": true,
       "requires": {
-        "amdefine": ">=0.0.4"
+        "amdefine": "1.0.1"
       }
     },
     "spdx-correct": {
@@ -2324,8 +2324,8 @@
       "integrity": 
"sha512-N19o9z5cEyc8yQQPukRCZ9EUmb4HUpnrmaL/fxS2pBo2jbfcFRVuFZ/oFC+vZz0MNNk0h80iMn5/S6qGZOL5+g==",
       "dev": true,
       "requires": {
-        "spdx-expression-parse": "^3.0.0",
-        "spdx-license-ids": "^3.0.0"
+        "spdx-expression-parse": "3.0.0",
+        "spdx-license-ids": "3.0.0"
       }
     },
     "spdx-exceptions": {
@@ -2340,8 +2340,8 @@
       "integrity": 
"sha512-Yg6D3XpRD4kkOmTpdgbUiEJFKghJH03fiC1OPll5h/0sO6neh2jqRDVHOQ4o/LMea0tgCkbMgea5ip/e+MkWyg==",
       "dev": true,
       "requires": {
-        "spdx-exceptions": "^2.1.0",
-        "spdx-license-ids": "^3.0.0"
+        "spdx-exceptions": "2.1.0",
+        "spdx-license-ids": "3.0.0"
       }
     },
     "spdx-license-ids": {
@@ -2361,15 +2361,15 @@
       "resolved": "https://registry.npmjs.org/sshpk/-/sshpk-1.14.2.tgz";,
       "integrity": "sha1-xvxhZIo9nE52T9P8306hBeSSupg=",
       "requires": {
-        "asn1": "~0.2.3",
-        "assert-plus": "^1.0.0",
-        "bcrypt-pbkdf": "^1.0.0",
-        "dashdash": "^1.12.0",
-        "ecc-jsbn": "~0.1.1",
-        "getpass": "^0.1.1",
-        "jsbn": "~0.1.0",
-        "safer-buffer": "^2.0.2",
-        "tweetnacl": "~0.14.0"
+        "asn1": "0.2.4",
+        "assert-plus": "1.0.0",
+        "bcrypt-pbkdf": "1.0.2",
+        "dashdash": "1.14.1",
+        "ecc-jsbn": "0.1.2",
+        "getpass": "0.1.7",
+        "jsbn": "0.1.1",
+        "safer-buffer": "2.1.2",
+        "tweetnacl": "0.14.5"
       }
     },
     "standard": {
@@ -2378,15 +2378,15 @@
       "integrity": 
"sha512-nu0jAcHiSc8H+gJCXeiziMVZNDYi8MuqrYJKxTgjP4xKXZMKm311boqQIzDrYI/ktosltxt2CbDjYQs9ANC8IA==",
       "dev": true,
       "requires": {
-        "eslint": "~4.18.0",
+        "eslint": "4.18.2",
         "eslint-config-standard": "11.0.0",
         "eslint-config-standard-jsx": "5.0.0",
-        "eslint-plugin-import": "~2.9.0",
-        "eslint-plugin-node": "~6.0.0",
-        "eslint-plugin-promise": "~3.7.0",
-        "eslint-plugin-react": "~7.7.0",
-        "eslint-plugin-standard": "~3.0.1",
-        "standard-engine": "~8.0.0"
+        "eslint-plugin-import": "2.9.0",
+        "eslint-plugin-node": "6.0.1",
+        "eslint-plugin-promise": "3.7.0",
+        "eslint-plugin-react": "7.7.0",
+        "eslint-plugin-standard": "3.0.1",
+        "standard-engine": "8.0.1"
       }
     },
     "standard-engine": {
@@ -2395,10 +2395,10 @@
       "integrity": 
"sha512-LA531C3+nljom/XRvdW/hGPXwmilRkaRkENhO3FAGF1Vtq/WtCXzgmnc5S6vUHHsgv534MRy02C1ikMwZXC+tw==",
       "dev": true,
       "requires": {
-        "deglob": "^2.1.0",
-        "get-stdin": "^6.0.0",
-        "minimist": "^1.1.0",
-        "pkg-conf": "^2.0.0"
+        "deglob": "2.1.1",
+        "get-stdin": "6.0.0",
+        "minimist": "1.2.0",
+        "pkg-conf": "2.1.0"
       },
       "dependencies": {
         "minimist": {
@@ -2415,8 +2415,8 @@
       "integrity": 
"sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==",
       "dev": true,
       "requires": {
-        "is-fullwidth-code-point": "^2.0.0",
-        "strip-ansi": "^4.0.0"
+        "is-fullwidth-code-point": "2.0.0",
+        "strip-ansi": "4.0.0"
       }
     },
     "string.prototype.trim": {
@@ -2425,9 +2425,9 @@
       "integrity": "sha1-0E3iyJ4Tf019IG8Ia17S+ua+jOo=",
       "dev": true,
       "requires": {
-        "define-properties": "^1.1.2",
-        "es-abstract": "^1.5.0",
-        "function-bind": "^1.0.2"
+        "define-properties": "1.1.2",
+        "es-abstract": "1.12.0",
+        "function-bind": "1.1.1"
       }
     },
     "string_decoder": {
@@ -2436,7 +2436,7 @@
       "integrity": 
"sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==",
       "dev": true,
       "requires": {
-        "safe-buffer": "~5.1.0"
+        "safe-buffer": "5.1.2"
       }
     },
     "strip-ansi": {
@@ -2445,7 +2445,7 @@
       "integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=",
       "dev": true,
       "requires": {
-        "ansi-regex": "^3.0.0"
+        "ansi-regex": "3.0.0"
       },
       "dependencies": {
         "ansi-regex": {
@@ -2474,7 +2474,7 @@
       "integrity": "sha1-ZawFBLOVQXHYpklGsq48u4pfVPY=",
       "dev": true,
       "requires": {
-        "has-flag": "^1.0.0"
+        "has-flag": "1.0.0"
       }
     },
     "table": {
@@ -2483,12 +2483,12 @@
       "integrity": 
"sha512-UUkEAPdSGxtRpiV9ozJ5cMTtYiqz7Ni1OGqLXRCynrvzdtR1p+cfOWe2RJLwvUG8hNanaSRjecIqwOjqeatDsA==",
       "dev": true,
       "requires": {
-        "ajv": "^5.2.3",
-        "ajv-keywords": "^2.1.0",
-        "chalk": "^2.1.0",
-        "lodash": "^4.17.4",
+        "ajv": "5.5.2",
+        "ajv-keywords": "2.1.1",
+        "chalk": "2.4.1",
+        "lodash": "4.17.10",
         "slice-ansi": "1.0.0",
-        "string-width": "^2.1.1"
+        "string-width": "2.1.1"
       }
     },
     "tape": {
@@ -2497,19 +2497,19 @@
       "integrity": 
"sha512-6fKIXknLpoe/Jp4rzHKFPpJUHDHDqn8jus99IfPnHIjyz78HYlefTGD3b5EkbQzuLfaEvmfPK3IolLgq2xT3kw==",
       "dev": true,
       "requires": {
-        "deep-equal": "~1.0.1",
-        "defined": "~1.0.0",
-        "for-each": "~0.3.3",
-        "function-bind": "~1.1.1",
-        "glob": "~7.1.2",
-        "has": "~1.0.3",
-        "inherits": "~2.0.3",
-        "minimist": "~1.2.0",
-        "object-inspect": "~1.6.0",
-        "resolve": "~1.7.1",
-        "resumer": "~0.0.0",
-        "string.prototype.trim": "~1.1.2",
-        "through": "~2.3.8"
+        "deep-equal": "1.0.1",
+        "defined": "1.0.0",
+        "for-each": "0.3.3",
+        "function-bind": "1.1.1",
+        "glob": "7.1.2",
+        "has": "1.0.3",
+        "inherits": "2.0.3",
+        "minimist": "1.2.0",
+        "object-inspect": "1.6.0",
+        "resolve": "1.7.1",
+        "resumer": "0.0.0",
+        "string.prototype.trim": "1.1.2",
+        "through": "2.3.8"
       },
       "dependencies": {
         "glob": {
@@ -2538,7 +2538,7 @@
           "integrity": 
"sha512-c7rwLofp8g1U+h1KNyHL/jicrKg1Ek4q+Lr33AL65uZTinUZHe30D5HlyN5V9NW0JX1D5dXQ4jqW5l7Sy/kGfw==",
           "dev": true,
           "requires": {
-            "path-parse": "^1.0.5"
+            "path-parse": "1.0.6"
           }
         }
       }
@@ -2561,7 +2561,7 @@
       "integrity": 
"sha512-jRCJlojKnZ3addtTOjdIqoRuPEKBvNXcGYqzO6zWZX8KfKEpnGY5jfggJQ3EjKuu8D4bJRr0y+cYJFmYbImXGw==",
       "dev": true,
       "requires": {
-        "os-tmpdir": "~1.0.2"
+        "os-tmpdir": "1.0.2"
       }
     },
     "tough-cookie": {
@@ -2569,8 +2569,8 @@
       "resolved": 
"https://registry.npmjs.org/tough-cookie/-/tough-cookie-2.4.3.tgz";,
       "integrity": 
"sha512-Q5srk/4vDM54WJsJio3XNn6K2sCG+CQ8G5Wz6bZhRZoAe/+TxjWB/GlFAnYEbkYVlON9FMk/fE3h2RLpPXo4lQ==",
       "requires": {
-        "psl": "^1.1.24",
-        "punycode": "^1.4.1"
+        "psl": "1.1.29",
+        "punycode": "1.4.1"
       }
     },
     "tunnel-agent": {
@@ -2578,7 +2578,7 @@
       "resolved": 
"https://registry.npmjs.org/tunnel-agent/-/tunnel-agent-0.6.0.tgz";,
       "integrity": "sha1-J6XeoGs2sEoKmWZ3SykIaPD8QP0=",
       "requires": {
-        "safe-buffer": "^5.0.1"
+        "safe-buffer": "5.1.2"
       }
     },
     "tweetnacl": {
@@ -2593,7 +2593,7 @@
       "integrity": "sha1-WITKtRLPHTVeP7eE8wgEsrUg23I=",
       "dev": true,
       "requires": {
-        "prelude-ls": "~1.1.2"
+        "prelude-ls": "1.1.2"
       }
     },
     "type-detect": {
@@ -2615,9 +2615,9 @@
       "dev": true,
       "optional": true,
       "requires": {
-        "source-map": "~0.5.1",
-        "uglify-to-browserify": "~1.0.0",
-        "yargs": "~3.10.0"
+        "source-map": "0.5.7",
+        "uglify-to-browserify": "1.0.2",
+        "yargs": "3.10.0"
       },
       "dependencies": {
         "source-map": {
@@ -2659,8 +2659,8 @@
       "integrity": 
"sha512-DpKm2Ui/xN7/HQKCtpZxoRWBhZ9Z0kqtygG8XCgNQ8ZlDnxuQmWhj566j8fN4Cu3/JmbhsDo7fcAJq4s9h27Ew==",
       "dev": true,
       "requires": {
-        "spdx-correct": "^3.0.0",
-        "spdx-expression-parse": "^3.0.0"
+        "spdx-correct": "3.0.0",
+        "spdx-expression-parse": "3.0.0"
       }
     },
     "verror": {
@@ -2668,9 +2668,9 @@
       "resolved": "https://registry.npmjs.org/verror/-/verror-1.10.0.tgz";,
       "integrity": "sha1-OhBcoXBTr1XW4nDB+CiGguGNpAA=",
       "requires": {
-        "assert-plus": "^1.0.0",
+        "assert-plus": "1.0.0",
         "core-util-is": "1.0.2",
-        "extsprintf": "^1.2.0"
+        "extsprintf": "1.3.0"
       }
     },
     "which": {
@@ -2679,7 +2679,7 @@
       "integrity": 
"sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==",
       "dev": true,
       "requires": {
-        "isexe": "^2.0.0"
+        "isexe": "2.0.0"
       }
     },
     "window-size": {
@@ -2707,7 +2707,7 @@
       "integrity": "sha1-X8A4KOJkzqP+kUVUdvejxWbLB1c=",
       "dev": true,
       "requires": {
-        "mkdirp": "^0.5.1"
+        "mkdirp": "0.5.1"
       }
     },
     "xtend": {
@@ -2729,9 +2729,9 @@
       "dev": true,
       "optional": true,
       "requires": {
-        "camelcase": "^1.0.2",
-        "cliui": "^2.1.0",
-        "decamelize": "^1.0.0",
+        "camelcase": "1.2.1",
+        "cliui": "2.1.0",
+        "decamelize": "1.2.0",
         "window-size": "0.1.0"
       }
     }
diff --git a/package.json b/package.json
index 1f35b55..3cd8f4a 100644
--- a/package.json
+++ b/package.json
@@ -32,7 +32,7 @@
     "tape": "^4.6.2"
   },
   "scripts": {
-    "test": "standard; bash scripts/run_couchdb_on_travis.sh; npm run mocha; 
bash scripts/stop_couchdb_on_travis.sh",
+    "test": "standard && npm run mocha",
     "mocha": "NOCK_OFF=true istanbul cover tape tests/*/*/*.js",
     "unmocked": "NOCK_OFF=true tape tests/*/*/*.js",
     "mocked": "tape tests/*/*/*.js",
diff --git a/tests/helpers/unit.js b/tests/helpers/unit.js
index 4016c6f..d5ab53f 100644
--- a/tests/helpers/unit.js
+++ b/tests/helpers/unit.js
@@ -89,9 +89,9 @@ helpers.unit = function (method, error) {
             stub.db = helpers.couch + stub.db
           }
 
-             if (method[1] === 'follow' || method[1] === 'followUpdates') {
-            assert.ok(typeof req.httpAgent, 'object');
-            delete req.httpAgent; // ignore 'httpAgent' in deep equal assert
+          if (method[1] === 'follow' || method[1] === 'followUpdates') {
+            assert.ok(typeof req.httpAgent, 'object')
+            delete req.httpAgent // ignore 'httpAgent' in deep equal assert
           }
 
           assert.deepEqual(req, stub)
diff --git a/tests/integration/attachment/pipe.js 
b/tests/integration/attachment/pipe.js
index df1ea5b..d861718 100644
--- a/tests/integration/attachment/pipe.js
+++ b/tests/integration/attachment/pipe.js
@@ -39,7 +39,7 @@ it('should be able to pipe to a writeStream', function 
(assert) {
 
 it('should be able to pipe to a writeStream', function (assert) {
   const ws = fs.createWriteStream('/dev/null')
-  const rs = db.attachment.getAsStream('new', 'att', function () {})
+  const rs = db.attachment.getAsStream('new', 'att')
   rs.pipe(ws)
   rs.on('end', function () {
     assert.end()
@@ -49,8 +49,7 @@ it('should be able to pipe to a writeStream', function 
(assert) {
 it('should be able to pipe from a readStream', function (assert) {
   const logo = path.join(__dirname, '..', '..', 'fixtures', 'logo.png')
   const rs = fs.createReadStream(logo)
-  const is = db.attachment.insertAsStream('nodejs', 'logo.png', null, 
'image/png', function () {
-  })
+  const is = db.attachment.insertAsStream('nodejs', 'logo.png', null, 
'image/png')
 
   is.on('end', function () {
     db.attachment.get('nodejs', 'logo.png', function (err, buffer) {
diff --git a/tests/integration/database/changes.js 
b/tests/integration/database/changes.js
index 14d93a6..953fd36 100644
--- a/tests/integration/database/changes.js
+++ b/tests/integration/database/changes.js
@@ -31,20 +31,31 @@ it('should be able to receive changes since seq:0', 
function (assert) {
 })
 
 it('should be able to receive changes since seq:0 as stream', function 
(assert) {
-  const p = db.changesAsStream({since: 0}, function (error, response) {
-    assert.equal(error, null, 'gets response from changes')
-    assert.equal(response.results.length, 3, 'gets three results')
-    assert.end()
-  })
+  const resp = []
+  const p = db.changesAsStream({since: 0})
+    .on('data', function (part) {
+      resp.push(part)
+    })
+    .on('error', function (error) {
+      assert.ifError(error)
+    })
+    .on('end', function () {
+      const response = JSON.parse(Buffer.concat(resp).toString('utf8'))
+      assert.equal(response.results.length, 3, 'gets three results')
+      assert.end()
+    })
   assert.ok(!helpers.isPromise(p), 'returns Promise')
   assert.equal(p.constructor.name, 'Request', 'returns a Request')
 })
 
 it('should be able to receive changes - no params - stream', function (assert) 
{
-  const p = db.changesAsStream(function (error) {
-    assert.equal(error, null, 'gets response from changes')
-    assert.end()
-  })
+  const p = db.changesAsStream()
+    .on('error', function (error) {
+      assert.ifError(error)
+    })
+    .on('end', function () {
+      assert.end()
+    })
   assert.ok(!helpers.isPromise(p), 'returns Promise')
   assert.equal(p.constructor.name, 'Request', 'returns a Request')
 })
diff --git a/tests/integration/design/multiple.js 
b/tests/integration/design/multiple.js
index 9082eef..1c86a10 100644
--- a/tests/integration/design/multiple.js
+++ b/tests/integration/design/multiple.js
@@ -55,16 +55,24 @@ it('get multiple docs with a composed key', function 
(assert) {
 })
 
 it('get multiple docs with a composed key as a stream', function (assert) {
+  const resp = []
   const p = db.viewAsStream('alice', 'by_id', {
     keys: ['foobar', 'barfoo'],
     'include_docs': true
-  }, function (err, view) {
-    assert.equal(err, null, 'should response')
-    assert.equal(view.rows.length, 2, 'has more or less than two rows')
-    assert.equal(view.rows[0].id, 'foobar', 'foo is not the first id')
-    assert.equal(view.rows[1].id, 'barfoo', 'bar is not the second id')
-    assert.end()
   })
+    .on('data', function (part) {
+      resp.push(part)
+    })
+    .on('error', function (error) {
+      assert.ifError(error)
+    })
+    .on('end', function () {
+      const view = JSON.parse(Buffer.concat(resp).toString('utf8'))
+      assert.equal(view.rows.length, 2, 'has more or less than two rows')
+      assert.equal(view.rows[0].id, 'foobar', 'foo is not the first id')
+      assert.equal(view.rows[1].id, 'barfoo', 'bar is not the second id')
+      assert.end()
+    })
   assert.ok(!helpers.isPromise(p), 'does not returns Promise')
   assert.equal(p.constructor.name, 'Request', 'returns a Request')
 })
diff --git a/tests/integration/document/find.js 
b/tests/integration/document/find.js
index 39f61ab..0dedc9e 100644
--- a/tests/integration/document/find.js
+++ b/tests/integration/document/find.js
@@ -32,11 +32,19 @@ it('should be to do a mango query', function (assert) {
 })
 
 it('should be to do a mango query with streams', function (assert) {
-  const p = db.findAsStream({selector: {foo: 'baz'}}, function (error, 
response) {
-    assert.equal(error, null, 'should work')
-    assert.equal(response.docs.length, 1, 'and get one row')
-    assert.end()
-  })
+  const resp = []
+  const p = db.findAsStream({selector: {foo: 'baz'}})
+    .on('data', function (part) {
+      resp.push(part)
+    })
+    .on('error', function (error) {
+      assert.ifError(error)
+    })
+    .on('end', function () {
+      const response = JSON.parse(Buffer.concat(resp).toString('utf8'))
+      assert.equal(response.docs.length, 1, 'and get one row')
+      assert.end()
+    })
   assert.ok(!helpers.isPromise(p), 'does not return Promise')
   assert.equal(p.constructor.name, 'Request', 'returns a Request')
 })
diff --git a/tests/integration/document/list.js 
b/tests/integration/document/list.js
index 0ecacb4..7be6624 100644
--- a/tests/integration/document/list.js
+++ b/tests/integration/document/list.js
@@ -106,23 +106,25 @@ it('should be able to list with a end_key', function 
(assert) {
 })
 
 it('should be able to list as a stream', function (assert) {
-  const p = db.listAsStream(function (error) {
-    assert.equal(error, null, 'should work')
-  })
+  const p = db.listAsStream()
+    .on('error', function (error) {
+      assert.ifError(error)
+    })
+    .on('end', function () {
+      assert.end()
+    })
   assert.ok(!helpers.isPromise(p), 'does not return Promise')
   assert.equal(p.constructor.name, 'Request', 'returns a Request')
-  p.on('end', function () {
-    assert.end()
-  })
 })
 
 it('should be able to list with params as a stream', function (assert) {
-  const p = db.listAsStream({end_key: 's'}, function (error) {
-    assert.equal(error, null, 'should work')
-  })
+  const p = db.listAsStream({end_key: 's'})
+    .on('error', function (error) {
+      assert.ifError(error)
+    })
+    .on('end', function () {
+      assert.end()
+    })
   assert.ok(!helpers.isPromise(p), 'does not return Promise')
   assert.equal(p.constructor.name, 'Request', 'returns a Request')
-  p.on('end', function () {
-    assert.end()
-  })
 })
diff --git a/tests/integration/shared/config.js 
b/tests/integration/shared/config.js
index a043b32..709ef84 100644
--- a/tests/integration/shared/config.js
+++ b/tests/integration/shared/config.js
@@ -102,10 +102,13 @@ it('should accept and handle customer http headers', 
function (assert) {
     }
   })
 
-  const req = nanoWithDefaultHeaders.db.listAsStream(function (err) {
-    assert.equal(err, null, 'should list')
-    assert.end()
-  })
+  const req = nanoWithDefaultHeaders.db.listAsStream()
+    .on('error', function (error) {
+      assert.ifError(error)
+    })
+    .on('end', function () {
+      assert.end()
+    })
 
   assert.equal(
     req.headers['x-custom-header'],
diff --git a/tests/intercept/design/search.js b/tests/intercept/design/search.js
index 3c8d1e8..535fae7 100644
--- a/tests/intercept/design/search.js
+++ b/tests/intercept/design/search.js
@@ -18,7 +18,11 @@ const it = harness.it
 
 const nano = require('../../../lib/nano.js')
 const fakeRequest = function (r, callback) {
-  callback(null, { statusCode: 200 }, r)
+  if (callback) {
+    callback(null, { statusCode: 200 }, r)
+  } else {
+    return r
+  }
 }
 // by passing in a fake Request object, we can intercept the request
 // and see how Nano is pre-processing the parameters
@@ -216,14 +220,11 @@ it('should not encode encoded string sort parameter', 
function (assert) {
 })
 
 it('should allow search results to be streamed', function (assert) {
-  db.searchAsStream('fake', 'fake',
-    { q: 'foo:bar' },
-    function (err, data) {
-      assert.equal(err, null)
-      assert.equal(data.method, 'GET')
-      assert.equal(typeof data.headers, 'object')
-      assert.equal(typeof data.qs, 'object')
-      assert.equal(data.qs.q, 'foo:bar')
-      assert.end()
-    })
+  const req = db.searchAsStream('fake', 'fake',
+    { q: 'foo:bar' })
+  assert.equal(req.method, 'GET')
+  assert.equal(typeof req.headers, 'object')
+  assert.equal(typeof req.qs, 'object')
+  assert.equal(req.qs.q, 'foo:bar')
+  assert.end()
 })
diff --git a/tests/unit/document/head.js b/tests/unit/document/head.js
index 9108b74..4fca606 100644
--- a/tests/unit/document/head.js
+++ b/tests/unit/document/head.js
@@ -10,27 +10,28 @@
 // License for the specific language governing permissions and limitations 
under
 // the License.
 
-'use strict';
+'use strict'
 
-const helpers = require('../../helpers/unit');
-const test = require('tape');
-const debug = require('debug')('nano/tests/unit/shared/error');
+const helpers = require('../../helpers/unit')
+const test = require('tape')
+const debug = require('debug')('nano/tests/unit/shared/error')
 
-const cli = helpers.mockClientDb(debug);
-const db = cli.use('foo');
+const cli = helpers.mockClientDb(debug)
+const db = cli.use('foo')
 
 test('it should return a promise when no callback is specified', function 
(assert) {
-  var p = db.head('doc');
+  var p = db.head('doc')
   p.then((headers) => {
-    assert.equal(headers.statusCode, 200);
-    assert.end();
-  });
-});
+    assert.equal(headers.statusCode, 200)
+    assert.end()
+  })
+})
 
 test('it should not return a promise when a callback is specified', function 
(assert) {
-  var p = db.head('doc', function(err, body, headers) {
-    assert.equal(headers.statusCode, 200);
-    assert.end();
-  });
-  assert.equal(typeof p, 'undefined');
-});
+  var p = db.head('doc', function (err, body, headers) {
+    assert.ifError(err)
+    assert.equal(headers.statusCode, 200)
+    assert.end()
+  })
+  assert.equal(typeof p, 'undefined')
+})


 

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to