Merge pull request #260 from ruanyl/master

fixed: popup overlay not removed when there is error
This commit is contained in:
Buu Nguyen 2016-02-11 13:43:44 -08:00
commit 92d081e5ef
2 changed files with 6 additions and 0 deletions

View File

@ -105,6 +105,7 @@ $(document).ready(() => {
adapter.getRepoFromPath(showInNonCodePage, currRepo, token, (err, repo) => {
if (err) {
showError(err)
helpPopup.clean()
}
else if (repo) {
$toggler.show()

View File

@ -4,6 +4,11 @@ class HelpPopup {
this.store = store
}
clean() {
const $view = this.$view
$view.remove()
}
show() {
const $view = this.$view
const store = this.store