File tree Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -21,17 +21,19 @@ async function main() {
2121 const directories = communityCodemods . filter ( dir => junk . not ( dir ) ) ;
2222
2323 for ( const dir of directories ) {
24- const { config } = await fetchConfig ( path . join ( COMMUNITY_PATH , dir ) ) ;
24+ const configMeta = await fetchConfig ( path . join ( COMMUNITY_PATH , dir ) ) ;
2525
26- if ( ! config ) {
26+ if ( ! configMeta ?. config ) {
2727 throw new Error ( `Unable to locate config for path: ${ dir } ` ) ;
2828 }
2929
3030 const pkgName = `@hypermod/mod-${ dir . replace ( '@' , '' ) . replace ( '/' , '__' ) } ` ;
3131 const rawPkgName = dir . replace ( '__' , '/' ) ;
3232 data . push ( {
3333 pkgName,
34- targets : rawPkgName + ( config . targets ? `, ${ config . targets } ` : '' ) ,
34+ targets :
35+ rawPkgName +
36+ ( configMeta . config . targets ? `, ${ configMeta . config . targets } ` : '' ) ,
3537 } ) ;
3638 }
3739
You can’t perform that action at this time.
0 commit comments