When running this script in a fresh vaulted installation, I get the following error:
Error: type not provided or has no length.
at API.mountEndpoints (node_modules/vaulted/lib/api.js:173:11)
at node_modules/vaulted/lib/internal.js:71:17
at node_modules/lodash/lodash.js:4944:15
at baseForOwn (node_modules/lodash/lodash.js:3001:24)
at node_modules/lodash/lodash.js:4913:18
at Function.forEach (node_modules/lodash/lodash.js:9359:14)
at Object.syncMounts (node_modules/vaulted/lib/internal.js:68:5)
at Vaulted.<anonymous> (node_modules/vaulted/lib/vaulted.js:65:14)
at Vaulted.tryCatcher (node_modules/bluebird/js/release/util.js:16:23)
at Promise._settlePromiseFromHandler (node_modules/bluebird/js/release/promise.js:512:31)
at Promise._settlePromise (node_modules/bluebird/js/release/promise.js:569:18)
at Promise._settlePromise0 (node_modules/bluebird/js/release/promise.js:614:10)
at Promise._settlePromises (node_modules/bluebird/js/release/promise.js:693:18)
at Async._drainQueue (node_modules/bluebird/js/release/async.js:133:16)
at Async._drainQueues (node_modules/bluebird/js/release/async.js:143:10)
at Immediate.Async.drainQueues (node_modules/bluebird/js/release/async.js:17:14)
This seems to be because of lib/sys/mounts.js#L42. There, the response from "request" is directly used. But, the actual mounts are in mounts.data. The same happens at lib/sys/auth.js#L39.
When running this script in a fresh vaulted installation, I get the following error:
This seems to be because of lib/sys/mounts.js#L42. There, the response from "request" is directly used. But, the actual mounts are in mounts.data. The same happens at lib/sys/auth.js#L39.
I will provide a pull request for this shortly.