only reset origin input if needed
This commit is contained in:
parent
d6a08e187e
commit
3030c264f4
1 changed files with 3 additions and 2 deletions
|
@ -32,8 +32,9 @@ c3nav = {
|
|||
view = ($origin.data('location') === null || $destination.data('location') === null) ? 'route-search' : 'route-result';
|
||||
} else {
|
||||
view = ($destination.data('location') === null) ? 'search' : 'location';
|
||||
// todo only if needed
|
||||
c3nav._locationinput_set($origin, null);
|
||||
if ($origin.data('location') !== null) {
|
||||
c3nav._locationinput_set($origin, null);
|
||||
}
|
||||
}
|
||||
c3nav._view = view;
|
||||
$('main').attr('data-view', view);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue