mirror of
https://github.com/clusterio/clusterio.git
synced 2026-11-22 00:13:12 +09:00
Fix incorrect JSDoc async return annotations
The return type of an async function should be documented as a Promise of what the function returns as this is what JSDoc expects.
This commit is contained in:
1 parent
a7dedcd3b7
commit
2d8b35291d
12 files changed
+33
-33
No files matched your search
@@ -205,7 +205,7 @@ class LogIndex {
|
||||
* module:lib/logging_utils.LogIndex#save}.
|
||||
*
|
||||
* @param {string} logDirectory - Path to directory to load from.
|
||||
* @returns {module:lib/logging_utils.LogIndex} loaded or created log index.
|
||||
* @returns {Promise<module:lib/logging_utils.LogIndex>} loaded or created log index.
|
||||
*/
|
||||
static async load(logDirectory) {
|
||||
try {
|
||||
@@ -391,7 +391,7 @@ function logFilter({ all, master, slave_ids, instance_ids, max_level }) {
|
||||
* Filter to limit logs by.
|
||||
* @param {module:lib/logging_utils.LogIndex=} index -
|
||||
* Index to speed up query with.
|
||||
* @returns {Array<Object>} log entries matching the filter
|
||||
* @returns {Promise<Array<Object>>} log entries matching the filter
|
||||
*/
|
||||
async function queryLog(logDirectory, filter, index) {
|
||||
let files = (await fs.readdir(logDirectory)).filter(entry => logFileGlob.test(entry));
|
||||
|
||||
Reference in new issue
Block a user