Skip to content

Commit

Permalink
fix: dispose first
Browse files Browse the repository at this point in the history
  • Loading branch information
Aaaaash committed Jan 8, 2025
1 parent a48505b commit 5feff59
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/file-service/src/node/hosted/watcher.host.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ import { WatcherProcessLogger } from './watch-process-log';

const watcherPlaceHolder = {
disposable: {
dispose: () => {},
dispose: () => { },
},
handlers: [],
};
Expand Down Expand Up @@ -77,9 +77,9 @@ export class WatcherHostServiceImpl implements IWatcherHostService {

// rewatch
for (const [_uri, { options, disposable }] of this.watcherCollection) {
this.doWatch(Uri.parse(_uri), options);
this.logger.log('rewatch file changes: ', _uri, ' recursive: ', options?.recursive);
disposable.dispose();
this.doWatch(Uri.parse(_uri), options);
}
}

Expand Down

0 comments on commit 5feff59

Please sign in to comment.