File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -649,14 +649,14 @@ namespace vfs {
649649 *
650650 * NOTE: do not rename this method as it is intended to align with the same named export of the "fs" module.
651651 */
652- public readFileSync ( path : string , encoding : string ) : string ;
652+ public readFileSync ( path : string , encoding : BufferEncoding ) : string ;
653653 /**
654654 * Read from a file.
655655 *
656656 * NOTE: do not rename this method as it is intended to align with the same named export of the "fs" module.
657657 */
658- public readFileSync ( path : string , encoding ?: string | null ) : string | Buffer ;
659- public readFileSync ( path : string , encoding : string | null = null ) { // eslint-disable-line no-null/no-null
658+ public readFileSync ( path : string , encoding ?: BufferEncoding | null ) : string | Buffer ;
659+ public readFileSync ( path : string , encoding : BufferEncoding | null = null ) { // eslint-disable-line no-null/no-null
660660 const { node } = this . _walk ( this . _resolve ( path ) ) ;
661661 if ( ! node ) throw createIOError ( "ENOENT" ) ;
662662 if ( isDirectory ( node ) ) throw createIOError ( "EISDIR" ) ;
You can’t perform that action at this time.
0 commit comments