mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-09 18:37:50 +00:00
More build fixes.
Former-commit-id: 8b97cd56c4b5530d03ba89d192be7df989e96655
This commit is contained in:
@@ -120,8 +120,7 @@
|
||||
source = fs.readFileSync(filePath, 'utf8');
|
||||
}
|
||||
|
||||
modes = options.modes || (options.modes = modes);
|
||||
|
||||
modes = options.modes || modes;
|
||||
if (options.isMapped) {
|
||||
modes = modes.filter(function(mode) {
|
||||
return mode != 'hybrid';
|
||||
@@ -129,9 +128,11 @@
|
||||
}
|
||||
if (options.isTemplate) {
|
||||
modes = modes.filter(function(mode) {
|
||||
mode != 'advanced';
|
||||
return mode != 'advanced';
|
||||
});
|
||||
}
|
||||
options.modes = modes;
|
||||
|
||||
// fetch the Closure Compiler
|
||||
getDependency({
|
||||
'id': 'closure-compiler',
|
||||
@@ -450,7 +451,7 @@
|
||||
if (this.modes.indexOf('advanced') > -1) {
|
||||
closureCompile.call(this, this.source, 'advanced', onClosureAdvancedCompile.bind(this));
|
||||
} else {
|
||||
onComplete.call(this);
|
||||
onClosureAdvancedGzip.call(this);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -28,7 +28,7 @@
|
||||
source = source.replace(/^\/\**[\s\S]+?\*\/\n/, '');
|
||||
|
||||
// move vars exposed by the Closure Compiler into the IIFE
|
||||
source = source.replace(/^((?:(['"])use strict\2;)?(?:var (?:[a-z]+=(?:!0|!1|null)[,;])+)?)([\s\S]*?function[^)]+\){)/, '$3$1');
|
||||
source = source.replace(/^((?:var (?:\w+=(?:!0|!1|null)[,;])+)?)([\s\S]*?function[^)]+\){)/, '$2$1');
|
||||
|
||||
// correct overly aggressive Closure Compiler advanced optimizations
|
||||
source = source
|
||||
|
||||
Reference in New Issue
Block a user