remove settimeout

pull/3094/head
yann300 7 years ago
parent dbafc50195
commit 3129369dfa
  1. 2
      src/app/compiler/compiler.js
  2. 2
      src/app/files/basicReadOnlyExplorer.js
  3. 2
      src/app/files/browser-files.js

@ -49,9 +49,7 @@ function Compiler (handleImportCall) {
self.lastCompilationResult = null self.lastCompilationResult = null
self.event.trigger('compilationFinished', [false, {'error': { formattedMessage: error, severity: 'error' }}, files]) self.event.trigger('compilationFinished', [false, {'error': { formattedMessage: error, severity: 'error' }}, files])
} else { } else {
setTimeout(function () {
compileJSON(input, optimize ? 1 : 0) compileJSON(input, optimize ? 1 : 0)
}, 0)
} }
}) })
} }

@ -108,7 +108,7 @@ class BasicReadOnlyExplorer {
'/content': self.get(path) '/content': self.get(path)
}) })
}) })
setTimeout(_ => callback(null, tree), 0) callback(null, tree)
} }
removePrefix (path) { removePrefix (path) {

@ -118,7 +118,6 @@ function Files (storage) {
this.resolveDirectory = function (path, callback) { this.resolveDirectory = function (path, callback) {
var self = this var self = this
// path = '' + (path || '') // path = '' + (path || '')
setTimeout(function () {
function hashmapize (obj, path, val) { function hashmapize (obj, path, val) {
var nodes = path.split('/') var nodes = path.split('/')
var i = 0 var i = 0
@ -153,7 +152,6 @@ function Files (storage) {
}) })
}) })
callback(null, tree) callback(null, tree)
}, 0)
} }
this.removePrefix = function (path) { this.removePrefix = function (path) {

Loading…
Cancel
Save