mirror of
https://github.com/jashkenas/coffeescript.git
synced 2026-05-03 03:00:14 -04:00
Remove always true if check (#5406)
This commit is contained in:
@@ -60,10 +60,8 @@
|
||||
// Save the options for compiling child imports.
|
||||
mainModule.options = options;
|
||||
// Compile.
|
||||
if (!helpers.isCoffee(mainModule.filename) || require.extensions) {
|
||||
answer = CoffeeScript.compile(code, options);
|
||||
code = (ref = answer.js) != null ? ref : answer;
|
||||
}
|
||||
answer = CoffeeScript.compile(code, options);
|
||||
code = (ref = answer.js) != null ? ref : answer;
|
||||
return mainModule._compile(code, mainModule.filename);
|
||||
};
|
||||
|
||||
|
||||
@@ -53,9 +53,8 @@ CoffeeScript.run = (code, options = {}) ->
|
||||
mainModule.options = options
|
||||
|
||||
# Compile.
|
||||
if not helpers.isCoffee(mainModule.filename) or require.extensions
|
||||
answer = CoffeeScript.compile code, options
|
||||
code = answer.js ? answer
|
||||
answer = CoffeeScript.compile code, options
|
||||
code = answer.js ? answer
|
||||
|
||||
mainModule._compile code, mainModule.filename
|
||||
|
||||
|
||||
Reference in New Issue
Block a user