Skip to content

Commit

Permalink
Clear history immediately when switching sources
Browse files Browse the repository at this point in the history
  • Loading branch information
bhousel committed Aug 20, 2017
1 parent 82f95f8 commit d667ee6
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions modules/ui/source_switch.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,8 @@ export function uiSourceSwitch(context) {
var live = d3.select(this)
.classed('live');

context.connection()
.switch(live ? keys[1] : keys[0]);

context.history().clearSaved();
context.connection().switch(live ? keys[1] : keys[0]);
context.enter(modeBrowse(context));
context.flush();

Expand Down

0 comments on commit d667ee6

Please sign in to comment.