mirror of
https://github.com/CommunitySolidServer/CommunitySolidServer.git
synced 2024-10-03 14:55:10 +00:00
refactor: Use node protocol when importing builtins
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import { EventEmitter } from 'events';
|
||||
import { EventEmitter } from 'node:events';
|
||||
|
||||
/**
|
||||
* A typed interface of {@link EventEmitter}.
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import type { IncomingHttpHeaders } from 'http';
|
||||
import type { IncomingHttpHeaders } from 'node:http';
|
||||
import escapeStringRegexp from 'escape-string-regexp';
|
||||
import { getLoggerFor } from '../logging/LogUtil';
|
||||
import type { HttpResponse } from '../server/HttpResponse';
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { posix, win32 } from 'path';
|
||||
import { posix, win32 } from 'node:path';
|
||||
import { readJson } from 'fs-extra';
|
||||
import urljoin from 'url-join';
|
||||
import type { TargetExtractor } from '../http/input/identifier/TargetExtractor';
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { types } from 'util';
|
||||
import { types } from 'node:util';
|
||||
import { createAggregateError } from './errors/HttpErrorUtil';
|
||||
|
||||
export type PromiseOrValue<T> = T | Promise<T>;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import type { Readable } from 'stream';
|
||||
import type { Readable } from 'node:stream';
|
||||
import type { NamedNode } from '@rdfjs/types';
|
||||
import arrayifyStream from 'arrayify-stream';
|
||||
import type { ParserOptions } from 'n3';
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import type { Readable, TransformCallback, TransformOptions } from 'stream';
|
||||
import { Transform } from 'stream';
|
||||
import type { Readable, TransformCallback, TransformOptions } from 'node:stream';
|
||||
import { Transform } from 'node:stream';
|
||||
import { RangeNotSatisfiedHttpError } from './errors/RangeNotSatisfiedHttpError';
|
||||
import { pipeSafely } from './StreamUtil';
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import type { DuplexOptions, ReadableOptions, Writable } from 'stream';
|
||||
import { Readable, Transform } from 'stream';
|
||||
import { promisify } from 'util';
|
||||
import type { DuplexOptions, ReadableOptions, Writable } from 'node:stream';
|
||||
import { Readable, Transform } from 'node:stream';
|
||||
import { promisify } from 'node:util';
|
||||
import arrayifyStream from 'arrayify-stream';
|
||||
import eos from 'end-of-stream';
|
||||
import { Store } from 'n3';
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { types } from 'util';
|
||||
import { types } from 'node:util';
|
||||
|
||||
/**
|
||||
* Checks if the input is an {@link Error}.
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { URL } from 'url';
|
||||
import { URL } from 'node:url';
|
||||
import type { ResourceIdentifier } from '../../http/representation/ResourceIdentifier';
|
||||
import { errorTermsToMetadata } from '../errors/HttpErrorUtil';
|
||||
import { InternalServerError } from '../errors/InternalServerError';
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { createHash } from 'crypto';
|
||||
import { createHash } from 'node:crypto';
|
||||
import { ensureDir, remove } from 'fs-extra';
|
||||
import type { LockOptions, UnlockOptions } from 'proper-lockfile';
|
||||
import { lock, unlock } from 'proper-lockfile';
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { promises as fsPromises } from 'fs';
|
||||
import { promises as fsPromises } from 'node:fs';
|
||||
import { joinFilePath, resolveAssetPath } from '../PathUtil';
|
||||
import type { Template } from './TemplateEngine';
|
||||
|
||||
|
||||
Reference in New Issue
Block a user