Skip to content

Commit

Permalink
$mol_file: fixed file adding watching
Browse files Browse the repository at this point in the history
  • Loading branch information
nin--jin committed Jun 25, 2018
1 parent 9ebd0a5 commit c188d61
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion file/file.node.ts
Expand Up @@ -28,7 +28,13 @@ namespace $ {
} )

watcher.on( 'all' , ( type : string , path : string )=> {
$mol_file.absolute( path.replace( /\\/g , '/' ) ).stat( undefined , $mol_atom_force_cache )

const file = $mol_file.absolute( path.replace( /\\/g , '/' ) )
file.stat( undefined , $mol_atom_force_cache )

if( type === 'change' ) return
file.parent().stat( undefined , $mol_atom_force_cache )

} )

watcher.on( 'error' , ( error : Error )=> {
Expand Down

0 comments on commit c188d61

Please sign in to comment.