File tree Expand file tree Collapse file tree 1 file changed +8
-4
lines changed Expand file tree Collapse file tree 1 file changed +8
-4
lines changed Original file line number Diff line number Diff line change 1
1
// @flow
2
- const { explodeModule } = require ( " babel-explode-module" ) ;
3
- const { explodedToStatements } = require ( " babel-helper-simplify-module" ) ;
2
+ const { explodeModule } = require ( ' babel-explode-module' ) ;
3
+ const { explodedToStatements } = require ( ' babel-helper-simplify-module' ) ;
4
4
const printAST = require ( 'ast-pretty-print' ) ;
5
- const t = require ( " babel-types" ) ;
5
+ const t = require ( ' babel-types' ) ;
6
6
7
7
module . exports = function matchExported (
8
8
file /* : Object */ ,
@@ -31,7 +31,11 @@ module.exports = function matchExported(
31
31
return null ;
32
32
}
33
33
34
- let statement = file . path . get ( "body" ) . find ( item => {
34
+ if ( local === 'default' && match . source ) {
35
+ local = exportName ;
36
+ }
37
+
38
+ let statement = file . path . get ( 'body' ) . find ( item => {
35
39
if ( ! item . isDeclaration ( ) ) return false ;
36
40
37
41
let id = null ;
You can’t perform that action at this time.
0 commit comments