mirror of
https://github.com/YGGverse/Yoda.git
synced 2026-04-02 01:25:27 +00:00
add new history record on request changed only
This commit is contained in:
parent
d3d6e859f0
commit
b00e5befde
3 changed files with 23 additions and 1 deletions
|
|
@ -95,7 +95,15 @@ impl Page {
|
|||
&request, true, // activate (page reload)
|
||||
);
|
||||
|
||||
navigation.history_add(request);
|
||||
// Add new history record on request change
|
||||
match navigation.history_current() {
|
||||
Some(current) => {
|
||||
if current != request {
|
||||
navigation.history_add(request);
|
||||
}
|
||||
}
|
||||
None => navigation.history_add(request),
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue