File tree Expand file tree Collapse file tree
uri-resolver-extensions/src Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -4,8 +4,8 @@ import { Tracer } from "@polywrap/tracing-js";
44import { Result } from "@polywrap/result" ;
55
66export interface MaybeUriOrManifest {
7- uri ?: string ;
8- manifest ?: Uint8Array ;
7+ uri ?: string | null ;
8+ manifest ?: Uint8Array | null ;
99}
1010
1111export const module = {
@@ -32,8 +32,8 @@ export const module = {
3232 invoker : Invoker ,
3333 wrapper : Uri ,
3434 path : string
35- ) : Promise < Result < Uint8Array | undefined , WrapError > > => {
36- return invoker . invoke < Uint8Array | undefined > ( {
35+ ) : Promise < Result < Uint8Array | null , WrapError > > => {
36+ return invoker . invoke < Uint8Array | null > ( {
3737 uri : wrapper . uri ,
3838 method : "getFile" ,
3939 args : {
Original file line number Diff line number Diff line change @@ -34,7 +34,7 @@ export class UriResolverExtensionFileReader implements IFileReader {
3434 path
3535 ) ;
3636 if ( ! result . ok ) return result ;
37- if ( result . value === undefined ) {
37+ if ( ! result . value ) {
3838 return ResultErr ( new Error ( `File not found at ${ path } ` ) ) ;
3939 }
4040 return {
You can’t perform that action at this time.
0 commit comments