Skip to content

Commit

Permalink
chore(putout) run-babel-plugins: rm source
Browse files Browse the repository at this point in the history
  • Loading branch information
coderaiser committed Aug 1, 2019
1 parent f08b074 commit b1f7c38
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
1 change: 0 additions & 1 deletion packages/putout/lib/putout.js
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,6 @@ function transform(ast, source, opts) {
...runBabelPlugins({
ast,
fix,
source,
babelPlugins,
}),
...runPlugins({
Expand Down
4 changes: 2 additions & 2 deletions packages/putout/lib/run-babel-plugins/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ const getMessage = (a) => a
.replace(/@babel\/plugin-|babel-plugin-/, '')
.replace(/-/g, ' ');

module.exports = ({fix, ast, source, babelPlugins}) => {
module.exports = ({fix, ast, babelPlugins}) => {
const places = [];

if (!babelPlugins)
Expand All @@ -18,7 +18,7 @@ module.exports = ({fix, ast, source, babelPlugins}) => {
const oldCode = print(ast);

for (const plugin of babelPlugins) {
transform(ast, source, plugin);
transform(ast, '', plugin);

// that's right, transform changes AST
const newCode = print(ast);
Expand Down

0 comments on commit b1f7c38

Please sign in to comment.