@@ -378,9 +378,9 @@ export class Volume implements FsCallbackApi, FsSynchronousApi {
378
378
} ) ;
379
379
} ;
380
380
381
- public readvSync = ( fd : number , buffers : ArrayBufferView [ ] , position : number | null ) : number => {
381
+ public readvSync = ( fd : number , buffers : ArrayBufferView [ ] , position ? : number | null ) : number => {
382
382
validateFd ( fd ) ;
383
- return this . _core . readv ( fd , buffers , position ) ;
383
+ return this . _core . readv ( fd , buffers , position ?? null ) ;
384
384
} ;
385
385
386
386
private readonly _readfile = ( id : TFileId , flagsNum : number , encoding : BufferEncoding ) : Buffer | string => {
@@ -438,7 +438,7 @@ export class Volume implements FsCallbackApi, FsSynchronousApi {
438
438
buffer : Buffer | ArrayBufferView | DataView ,
439
439
offset ?: number ,
440
440
length ?: number ,
441
- position ?: number ,
441
+ position ?: number | null ,
442
442
) : number ;
443
443
( fd : number , str : string , position ?: number , encoding ?: BufferEncoding ) : number ;
444
444
} = (
@@ -524,9 +524,9 @@ export class Volume implements FsCallbackApi, FsSynchronousApi {
524
524
} ) ;
525
525
} ;
526
526
527
- public writevSync = ( fd : number , buffers : ArrayBufferView [ ] , position : number | null ) : number => {
527
+ public writevSync = ( fd : number , buffers : ArrayBufferView [ ] , position ? : number | null ) : void => {
528
528
validateFd ( fd ) ;
529
- return this . writevBase ( fd , buffers , position ) ;
529
+ this . writevBase ( fd , buffers , position ?? null ) ;
530
530
} ;
531
531
532
532
public writeFileSync = ( id : TFileId , data : TData , options ?: opts . IWriteFileOptions ) : void => {
0 commit comments