mirror of
https://github.com/linux-odyssey/linux-odyssey.git
synced 2026-11-05 19:20:12 +08:00
fix: eslint unused error
This commit is contained in:
1 parent
455fde41ab
commit
27b6096633
2 files changed
+3
-3
No files matched your search
@@ -26,7 +26,7 @@ const api = axios.create({
|
|||||||
async function readOrNone(file) {
|
async function readOrNone(file) {
|
||||||
try {
|
try {
|
||||||
return await fs.readFile(file, 'utf8')
|
return await fs.readFile(file, 'utf8')
|
||||||
} catch (err) {
|
} catch (_) {
|
||||||
return ''
|
return ''
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -25,7 +25,7 @@ async function collectFilesInfo(inputPath, level = 0, hiddenFiles = false) {
|
|||||||
)
|
)
|
||||||
)
|
)
|
||||||
files.push(...result.flat())
|
files.push(...result.flat())
|
||||||
} catch (err) {
|
} catch (_) {
|
||||||
// ignore
|
// ignore
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -41,7 +41,7 @@ async function discoverFiles(argv) {
|
|||||||
.map((p) => collectFilesInfo(p, 0, argv.a || argv.all))
|
.map((p) => collectFilesInfo(p, 0, argv.a || argv.all))
|
||||||
)
|
)
|
||||||
return { discover: result.flat() }
|
return { discover: result.flat() }
|
||||||
} catch (err) {
|
} catch (_) {
|
||||||
return {}
|
return {}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in new issue
Block a user