Skip to content

Commit

Permalink
fix(ui): unset last opened project if it is removed
Browse files Browse the repository at this point in the history
  • Loading branch information
Guillaume Chau committed Apr 30, 2018
1 parent d039af0 commit 29e2d76
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions packages/@vue/cli-ui/src/graphql-api/connectors/projects.js
Original file line number Diff line number Diff line change
Expand Up @@ -333,6 +333,9 @@ async function remove (id, context) {
currentProject = null
}
context.db.get('projects').remove({ id }).write()
if (context.db.get('config.lastOpenProject').value() === id) {
context.db.set('config.lastOpenProject', undefined).write()
}
return true
}

Expand Down

0 comments on commit 29e2d76

Please sign in to comment.