@@ -70,7 +70,7 @@ export class LogDecoder {
70
70
}
71
71
72
72
public deserialize ( components : types . LogComponentsWithFrontier , params : DeserializeParams = { } ) : DecodeResult {
73
- const [ view , metadata , model , , ...frontier ] = components ;
73
+ const [ view , header , model , , ...frontier ] = components ;
74
74
const result : DecodeResult = { } ;
75
75
if ( params . view ) result . view = view ;
76
76
if ( params . history ) result . history = this . deserializeHistory ( components ) ;
@@ -79,7 +79,7 @@ export class LogDecoder {
79
79
if ( result . history ) {
80
80
result . frontier = result . history ;
81
81
} else if ( model ) {
82
- const modelFormat = metadata [ 1 ] ;
82
+ const modelFormat = header [ 1 ] ;
83
83
const start = ( ) : Model => {
84
84
const isSidecar = modelFormat === FileModelEncoding . SidecarBinary ;
85
85
if ( isSidecar ) {
@@ -102,7 +102,7 @@ export class LogDecoder {
102
102
}
103
103
104
104
public deserializeHistory ( components : types . LogComponentsWithFrontier ) : Log {
105
- const [ , , , history , ...frontier ] = components ;
105
+ const [ , header , , history , ...frontier ] = components ;
106
106
const [ startSerialized ] = history ;
107
107
const start = ( ) : Model => {
108
108
if ( ! history || ! startSerialized ) {
@@ -112,7 +112,7 @@ export class LogDecoder {
112
112
}
113
113
return this . deserializeModel ( startSerialized ) ;
114
114
} ;
115
- const log = new Log ( start ) ;
115
+ const log = new Log ( start , void 0 , header [ 0 ] ) ;
116
116
const end = log . end ;
117
117
if ( history ) {
118
118
const [ , patches ] = history ;
0 commit comments