File tree 1 file changed +2
-5
lines changed
1 file changed +2
-5
lines changed Original file line number Diff line number Diff line change @@ -596,6 +596,7 @@ THREE.Object3D.prototype = {
596
596
var isRootObject = ( meta === undefined ) ;
597
597
598
598
var data = { } ;
599
+ var output = { object : data } ;
599
600
600
601
// meta is a hash used to collect geometries, materials.
601
602
// not providing it implies that this is the root object
@@ -610,7 +611,7 @@ THREE.Object3D.prototype = {
610
611
images : { }
611
612
} ;
612
613
613
- data . metadata = {
614
+ output . metadata = {
614
615
version : 4.4 ,
615
616
type : 'Object' ,
616
617
generator : 'Object3D.toJSON'
@@ -641,8 +642,6 @@ THREE.Object3D.prototype = {
641
642
642
643
}
643
644
644
- var output = { } ;
645
-
646
645
if ( isRootObject ) {
647
646
648
647
var geometries = extractFromCache ( meta . geometries ) ;
@@ -657,8 +656,6 @@ THREE.Object3D.prototype = {
657
656
658
657
}
659
658
660
- output . object = data ;
661
-
662
659
return output ;
663
660
664
661
// extract data from the cache hash
You can’t perform that action at this time.
0 commit comments