Skip to content
This repository was archived by the owner on Feb 12, 2024. It is now read-only.

Commit adb937e

Browse files
committed
chore: fix linting
1 parent a848c6b commit adb937e

File tree

2 files changed

+3
-23
lines changed

2 files changed

+3
-23
lines changed

src/cli/commands/add.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@ const multibase = require('multibase')
88
const { createProgressBar } = require('../utils')
99
const { cidToString } = require('../../utils/cid')
1010
const globSource = require('ipfs-utils/src/files/glob-source')
11-
const errcode = require('err-code')
1211

1312
async function getTotalBytes (paths) {
1413
const sizes = await Promise.all(paths.map(p => getFolderSize(p)))

src/core/components/files-mfs.js

Lines changed: 3 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,8 @@ module.exports = (/** @type { import("../index") } */ ipfs) => {
6969
/**
7070
* Change file mode
7171
*
72-
* @param {String} path - The path(s) of the source to modify.
72+
* @param {String} path - The path of the source to modify.
73+
* @param {Object} mode - The mode to set the path
7374
* @param {Object} [opts] - Options for modification.
7475
* @param {boolean} [opts.recursive=false] - Whether to change modes recursively. (default: false)
7576
* @param {boolean} [opts.flush=true] - Whether or not to immediately flush MFS changes to disk (default: true).
@@ -229,30 +230,10 @@ module.exports = (/** @type { import("../index") } */ ipfs) => {
229230
*/
230231
readPullStream: (path, opts = {}) => toPullStream.source(methods.read(path, opts)),
231232

232-
/**
233-
* Update modification time
234-
*
235-
* @param {String} path - The path(s) of the source to modify.
236-
* @param {Object} [opts] - Options for copy.
237-
* @param {boolean} [opts.parents=false] - Whether or not to make the parent directories if they don't exist. (default: false)
238-
* @param {String} [opts.format=dag-pb] - Format of nodes to write any newly created directories as. (default: dag-pb)
239-
* @param {String} [opts.hashAlg=sha2-256] - Algorithm to use when creating CIDs for newly created directories. (default: sha2-256) {@link https://github.com/multiformats/js-multihash/blob/master/src/constants.js#L5-L343 The list of all possible values}
240-
* @param {boolean} [opts.flush=true] - Whether or not to immediately flush MFS changes to disk (default: true).
241-
* @param {function(Error): void} [cb] - Callback function.
242-
* @returns {Promise<string> | void} When callback is provided nothing is returned.
243-
*/
244-
touch: (path, opts, cb) => {
245-
if (typeof opts === 'function') {
246-
cb = opts
247-
opts = {}
248-
}
249-
return nodeify(methods.touch(path, opts), cb)
250-
},
251-
252233
/**
253234
* Update modification time
254235
*
255-
* @param {String} path - The path(s) of the source to modify.
236+
* @param {String} path - The path of the source to modify.
256237
* @param {number} mtime - Time to use as the new modification time in seconds since (+ve) or before (-ve) the Unix Epoch
257238
* @param {Object} [opts] - Options for touch.
258239
* @param {boolean} [opts.parents=false] - Whether or not to make the parent directories if they don't exist. (default: false)

0 commit comments

Comments
 (0)