Skip to content

Commit

Permalink
GLTFExporter: Clean up.
Browse files Browse the repository at this point in the history
  • Loading branch information
mrdoob committed Apr 8, 2022
1 parent 88ef71e commit 340d588
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions examples/jsm/exporters/GLTFExporter.js
Original file line number Diff line number Diff line change
Expand Up @@ -349,15 +349,15 @@ function getCanvas() {

if ( typeof OffscreenCanvas !== 'undefined' ) {

const canvas = new OffscreenCanvas( 1, 1 );
cachedCanvas = canvas;
return canvas;
cachedCanvas = new OffscreenCanvas( 1, 1 );

} else {

cachedCanvas = document.createElement( 'canvas' );

}

const canvas = document.createElement( 'canvas' );
cachedCanvas = canvas;
return canvas;
return cachedCanvas;

}

Expand Down

0 comments on commit 340d588

Please sign in to comment.