@@ -184,19 +184,15 @@ module.exports = class URDNA2015Sync {
184184
185185 // 3.1.1) If any component in quad is an blank node, then serialize it
186186 // using a special identifier as follows:
187- const copy = {
188- subject : null , predicate : quad . predicate , object : null , graph : null
189- } ;
190187 // 3.1.2) If the blank node's existing blank node identifier matches
191188 // the reference blank node identifier then use the blank node
192189 // identifier _:a, otherwise, use the blank node identifier _:z.
193- copy . subject = this . modifyFirstDegreeComponent (
194- id , quad . subject , 'subject' ) ;
195- copy . object = this . modifyFirstDegreeComponent (
196- id , quad . object , 'object' ) ;
197- copy . graph = this . modifyFirstDegreeComponent (
198- id , quad . graph , 'graph' ) ;
199- nquads . push ( NQuads . serializeQuad ( copy ) ) ;
190+ nquads . push ( NQuads . serializeQuadComponents (
191+ this . modifyFirstDegreeComponent ( id , quad . subject , 'subject' ) ,
192+ quad . predicate ,
193+ this . modifyFirstDegreeComponent ( id , quad . object , 'object' ) ,
194+ this . modifyFirstDegreeComponent ( id , quad . graph , 'graph' )
195+ ) ) ;
200196 }
201197
202198 // 4) Sort nquads in lexicographical order.
0 commit comments