Skip to content

Commit

Permalink
view: update view when removing query
Browse files Browse the repository at this point in the history
If the active view is the message being removed, remove it, then
navigate to the connection console. Otherwise, just remove the message
and don't navigate anywhere. Just re-render
  • Loading branch information
evanlucas committed Apr 5, 2016
1 parent 7f60d33 commit 919530c
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions lib/views/sidebar/messages.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,10 @@ Messages.prototype.oncontextmenu = function oncontextmenu(e, message) {
label: 'Close Message'
, click: () => {
debug('removing message')
const conn = message.conn
message.partAndDestroy()
if (this.target.url === message.url)
this.target.router.goto(conn.url)
}
}))

Expand Down

0 comments on commit 919530c

Please sign in to comment.