fix watchBuild throw error, fix #18

This commit is contained in:
chemzqm 2019-04-12 19:23:36 +08:00
parent aab02eb8a6
commit cd7391f846

View file

@ -42,9 +42,9 @@ export default class WatchProject implements Disposable {
) {
this.statusItem = workspace.createStatusBarItem(1, { progress: true })
let task = this.task = workspace.createTask('TSC')
this.options = this.getOptions()
this.disposables.push(commandManager.registerCommand(WatchProject.id, async () => {
await this.start(this.options)
let opts = this.options = this.getOptions()
await this.start(opts)
}))
task.onExit(code => {
if (code != 0) {