mirror of
https://github.com/CommunitySolidServer/CommunitySolidServer.git
synced 2024-10-03 14:55:10 +00:00
chore: Update @antfu/eslint-config dependency to 2.11.4
This commit is contained in:
@@ -300,7 +300,7 @@ export class RepresentationMetadata {
|
||||
predicate: Term | string | null,
|
||||
object: Term | string | null,
|
||||
graph: Term | string | null) => boolean;
|
||||
}).has(this.id, predicate, object, graph) as boolean;
|
||||
}).has(this.id, predicate, object, graph);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -84,7 +84,7 @@ export class ExtensionBasedMapper extends BaseFileIdentifierMapper {
|
||||
const extension = getExtension(filePath).toLowerCase();
|
||||
return mime.lookup(extension) ||
|
||||
this.customTypes[extension] ||
|
||||
await super.getContentTypeFromPath(filePath);
|
||||
await super.getContentTypeFromPath(filePath);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -55,7 +55,7 @@ function emitStoredErrors(this: Guarded, event: string, func: (error: Error) =>
|
||||
if (event === 'error' && func !== guardingErrorListener) {
|
||||
// Cancel an error timeout
|
||||
if (this[guardedTimeout]) {
|
||||
clearTimeout(this[guardedTimeout]!);
|
||||
clearTimeout(this[guardedTimeout]);
|
||||
this[guardedTimeout] = undefined;
|
||||
}
|
||||
|
||||
|
||||
@@ -7,8 +7,8 @@ export function isError(error: unknown): error is Error {
|
||||
return types.isNativeError(error) ||
|
||||
(Boolean(error) &&
|
||||
typeof (error as Error).name === 'string' &&
|
||||
typeof (error as Error).message === 'string' &&
|
||||
(typeof (error as Error).stack === 'undefined' || typeof (error as Error).stack === 'string'));
|
||||
typeof (error as Error).message === 'string' &&
|
||||
(typeof (error as Error).stack === 'undefined' || typeof (error as Error).stack === 'string'));
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -48,7 +48,7 @@ export class HttpError<T extends number = number> extends Error implements HttpE
|
||||
public static isInstance(error: unknown): error is HttpError {
|
||||
return isError(error) &&
|
||||
typeof (error as HttpError).statusCode === 'number' &&
|
||||
Boolean((error as HttpError).metadata);
|
||||
Boolean((error as HttpError).metadata);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user