From aedcbda69178406f098abffd731e6ff87e39bf1e Mon Sep 17 00:00:00 2001 From: Gareth Jones Date: Sun, 7 Jul 2019 10:10:33 +1200 Subject: [PATCH] =?UTF-8?q?fix:=20=F0=9F=90=9B=20adjust=20definition=20of?= =?UTF-8?q?=20`TCallback`=20to=20accept=20`null`=20for=20`error`=20paramet?= =?UTF-8?q?er?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/volume.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/volume.ts b/src/volume.ts index 878cc115..446fb66e 100644 --- a/src/volume.ts +++ b/src/volume.ts @@ -57,7 +57,7 @@ export type TData = TDataOut | Uint8Array; // Data formats users can give us. export type TFlags = string | number; export type TMode = string | number; // Mode can be a String, although docs say it should be a Number. export type TTime = number | string | Date; -export type TCallback = (error?: IError, data?: TData) => void; +export type TCallback = (error?: IError | null, data?: TData) => void; // type TCallbackWrite = (err?: IError, bytesWritten?: number, source?: Buffer) => void; // type TCallbackWriteStr = (err?: IError, written?: number, str?: string) => void; export type TSymlinkType = 'file' | 'dir' | 'junction';