mirror of
https://github.com/atom/atom.git
synced 2026-01-22 21:38:10 -05:00
🐎 inline vm compatibility patch
This commit is contained in:
@@ -66,8 +66,7 @@
|
||||
"temp": "0.8.1",
|
||||
"text-buffer": "^4.1.5",
|
||||
"theorist": "^1.0.2",
|
||||
"underscore-plus": "^1.6.6",
|
||||
"vm-compatibility-layer": "0.1.0"
|
||||
"underscore-plus": "^1.6.6"
|
||||
},
|
||||
"packageDependencies": {
|
||||
"atom-dark-syntax": "0.26.0",
|
||||
|
||||
@@ -44,8 +44,7 @@ window.onload = function() {
|
||||
extra: {_version: loadSettings.appVersion}
|
||||
});
|
||||
|
||||
require('vm-compatibility-layer');
|
||||
|
||||
setupVmCompatibility();
|
||||
setupCsonCache(cacheDir);
|
||||
setupSourceMapCache(cacheDir);
|
||||
setup6to5(cacheDir);
|
||||
@@ -104,3 +103,9 @@ var setupCsonCache = function(cacheDir) {
|
||||
var setupSourceMapCache = function(cacheDir) {
|
||||
require('coffeestack').setCacheDirectory(path.join(cacheDir, 'coffee', 'source-maps'));
|
||||
}
|
||||
|
||||
var setupVmCompatibility = function() {
|
||||
var vm = require('vm');
|
||||
if (!vm.Script.createContext)
|
||||
vm.Script.createContext = vm.createContext;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user