File tree Expand file tree Collapse file tree 1 file changed +6
-5
lines changed
packages/host/src/lib/streamWrapper Expand file tree Collapse file tree 1 file changed +6
-5
lines changed Original file line number Diff line number Diff line change @@ -25,14 +25,15 @@ export abstract class BaseStreamWrapper<WrappedStream extends Stream> implements
25
25
26
26
static hasWrapperData < WrappedStream extends Stream > ( stream : WrappedStream ) { return "wrapperData" in stream ; }
27
27
static retriveWrapperData < WrappedStream extends Stream > ( stream : WrappedStream ) : WrapperData {
28
- if ( ! this . hasWrapperData ) throw new Error ( "Stream doesn't contain wrapper data" ) ;
28
+ // TODO: Add after KM, remove return || default values
29
+ // if (!this.hasWrapperData) throw new Error("Stream doesn't contain wrapper data");
29
30
const wrappedData : WrapperData = ( stream as any ) . wrapperData ;
30
31
31
32
return {
32
- id : wrappedData . id ,
33
- type : wrappedData . type ,
34
- origin : wrappedData . origin ,
35
- options : wrappedData . options ,
33
+ id : wrappedData . id || "" ,
34
+ type : wrappedData . type || "instance" ,
35
+ origin : wrappedData . origin || { id : "" , type : "hub" } ,
36
+ options : wrappedData . options || { } ,
36
37
} ;
37
38
}
38
39
You can’t perform that action at this time.
0 commit comments