diff --git a/editor/index.html b/editor/index.html
index 2a1b46a39d5051bf891db061b5a98d0b2bda5dc4..35730d48ca6c43c49b422a87bb4c9b7efd756e53 100644
--- a/editor/index.html
+++ b/editor/index.html
@@ -207,6 +207,8 @@
editor.storage.get( function ( state ) {
+ if ( isLoadingFromHash ) return;
+
if ( state !== undefined ) {
editor.fromJSON( state );
@@ -338,6 +340,7 @@
//
+ var isLoadingFromHash = false;
var hash = window.location.hash;
if ( hash.substr( 1, 5 ) === 'file=' ) {
@@ -350,13 +353,13 @@
loader.crossOrigin = '';
loader.load( file, function ( text ) {
- var json = JSON.parse( text );
-
editor.clear();
- editor.fromJSON( json );
+ editor.fromJSON( JSON.parse( text ) );
} );
+ isLoadingFromHash = true;
+
}
}