Skip to content

Commit 29e2d76

Browse files
author
Guillaume Chau
committed
fix(ui): unset last opened project if it is removed
1 parent d039af0 commit 29e2d76

File tree

1 file changed

+3
-0
lines changed
  • packages/@vue/cli-ui/src/graphql-api/connectors

1 file changed

+3
-0
lines changed

packages/@vue/cli-ui/src/graphql-api/connectors/projects.js

+3
Original file line numberDiff line numberDiff line change
@@ -333,6 +333,9 @@ async function remove (id, context) {
333333
currentProject = null
334334
}
335335
context.db.get('projects').remove({ id }).write()
336+
if (context.db.get('config.lastOpenProject').value() === id) {
337+
context.db.set('config.lastOpenProject', undefined).write()
338+
}
336339
return true
337340
}
338341

0 commit comments

Comments
 (0)