From 0e6de2c31dbf8c21277481f112e99c52b913940f Mon Sep 17 00:00:00 2001 From: Florian Dold Date: Wed, 27 Dec 2017 19:33:54 +0100 Subject: node_modules --- node_modules/babel-traverse/lib/path/replacement.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'node_modules/babel-traverse/lib/path/replacement.js') diff --git a/node_modules/babel-traverse/lib/path/replacement.js b/node_modules/babel-traverse/lib/path/replacement.js index a60c73d54..411dacf3f 100644 --- a/node_modules/babel-traverse/lib/path/replacement.js +++ b/node_modules/babel-traverse/lib/path/replacement.js @@ -140,7 +140,7 @@ function replaceWith(replacement) { } if (this.isNodeType("Statement") && t.isExpression(replacement)) { - if (!this.canHaveVariableDeclarationOrExpression() && !this.canSwapBetweenExpressionAndStatement(replacement)) { + if (!this.canHaveVariableDeclarationOrExpression() && !this.canSwapBetweenExpressionAndStatement(replacement) && !this.parentPath.isExportDefaultDeclaration()) { replacement = t.expressionStatement(replacement); } } -- cgit v1.2.3