mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 12:47:35 +00:00
Browser: Remove previous history entry in History::replace_current()
The lack of this action caused a bug in my original patch (https://github.com/SerenityOS/serenity/pull/16004) that appeared when accessing a site that redirected the client and it was the first site the client loaded.
This commit is contained in:
parent
8e16588757
commit
f3763a5275
1 changed files with 1 additions and 0 deletions
|
@ -35,6 +35,7 @@ void History::replace_current(const URL& url, String const& title)
|
||||||
if (m_current == -1)
|
if (m_current == -1)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
m_items.remove(m_current);
|
||||||
m_current--;
|
m_current--;
|
||||||
push(url, title);
|
push(url, title);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue