missing "this" for reference

pull/1/head
yann300 6 years ago
parent 658a6ffdc8
commit c5aafbfacb
  1. 8
      src/app/editor/SourceHighlighters.js
  2. 2
      src/app/tabs/compile-tab.js

@ -23,14 +23,14 @@ module.exports = class SourceHighlighters {
} catch (e) { } catch (e) {
return cb(e.message) return cb(e.message)
} }
if (!highlighters[mod]) highlighters[mod] = new SourceHighlighter() if (!this.highlighters[mod]) this.highlighters[mod] = new SourceHighlighter()
highlighters[mod].currentSourceLocation(null) this.highlighters[mod].currentSourceLocation(null)
highlighters[mod].currentSourceLocationFromfileName(position, filePath, hexColor) this.highlighters[mod].currentSourceLocationFromfileName(position, filePath, hexColor)
cb() cb()
} }
discardHighlight (mod, cb) { discardHighlight (mod, cb) {
if (highlighters[mod]) highlighters[mod].currentSourceLocation(null) if (this.highlighters[mod]) this.highlighters[mod].currentSourceLocation(null)
cb() cb()
} }
} }

@ -181,7 +181,7 @@ module.exports = class CompileTab {
}) })
} }
getCompilationResult (cb) { getCompilationResult (cb) {
cb(null, self._components.compiler.lastCompilationResult) cb(null, this._components.compiler.lastCompilationResult)
} }
profile () { profile () {
return { return {

Loading…
Cancel
Save