Skip to content

Commit cce41c9

Browse files
committed
Forward more options
1 parent 3eaa8cd commit cce41c9

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

lib/drives/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ class DriveManager extends EventEmitter {
112112
newDrive = true
113113
}
114114

115-
const corestore = this.megastore.get(name, { ...this.opts })
115+
const corestore = this.megastore.get(name, { ...this.opts, ...opts })
116116
const driveOpts = {
117117
...opts,
118118
sparse: opts.sparse !== false,

lib/fuse/index.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ class FuseManager extends EventEmitter {
122122
})
123123
}
124124

125-
return this.driveManager.get(key, this.opts)
125+
return this.driveManager.get(key, { ...this.opts, seed: false })
126126
.then(drive => {
127127
var handlers = this._handlers.get(drive)
128128
if (!handlers) {
@@ -239,7 +239,7 @@ class FuseManager extends EventEmitter {
239239
async _driveForPath (path, opts = {}) {
240240
return new Promise(async (resolve, reject) => {
241241
if (!this._rootDrive) {
242-
const drive = await this.driveManager.get(opts.key, { ...opts, configure: { rootDrive: true } })
242+
const drive = await this.driveManager.get(opts.key, { ...opts, seed: false, configure: { rootDrive: true } })
243243
return resolve({ drive, root: true })
244244
}
245245
if (path.startsWith(this._rootMnt) && path !== this._rootMnt) {
@@ -249,12 +249,12 @@ class FuseManager extends EventEmitter {
249249
return this._rootDrive.readFile(p.join(relativePath, '.key'), (err, key) => {
250250
if (err && err.errno !== 2) return reject(err)
251251
key = key ? datEncoding.decode(key.toString('utf8')) : opts.key
252-
return this.driveManager.get(key, opts)
252+
return this.driveManager.get(key, { ...opts, seed: false })
253253
.then(drive => resolve({ drive, root: false, relativePath }))
254254
.catch(reject)
255255
})
256256
}
257-
return { drive: this._rootDrive, root: true }
257+
return resolve({ drive: this._rootDrive, root: true })
258258
})
259259
}
260260

0 commit comments

Comments
 (0)