mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-30 20:59:16 +00:00
LibWeb: Simplify populate_session_history_entry_document conditional
This commit is contained in:
parent
41f574155d
commit
bd3ffcdabb
Notes:
github-actions[bot]
2024-10-14 18:50:07 +00:00
Author: https://github.com/shannonbooth
Commit: bd3ffcdabb
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/1780
1 changed files with 1 additions and 1 deletions
|
@ -1178,7 +1178,7 @@ WebIDL::ExceptionOr<void> Navigable::populate_session_history_entry_document(
|
||||||
// header specifying the attachment disposition type, then:
|
// header specifying the attachment disposition type, then:
|
||||||
// 6. Otherwise, if navigationParams's response's status is not 204 and is not 205, then set entry's document state's document to the result of
|
// 6. Otherwise, if navigationParams's response's status is not 204 and is not 205, then set entry's document state's document to the result of
|
||||||
// loading a document given navigationParams, sourceSnapshotParams, and entry's document state's initiator origin.
|
// loading a document given navigationParams, sourceSnapshotParams, and entry's document state's initiator origin.
|
||||||
else if (navigation_params.get<JS::NonnullGCPtr<NavigationParams>>()->response->status() != 204 && navigation_params.get<JS::NonnullGCPtr<NavigationParams>>()->response->status() != 205) {
|
else if (auto const& response = navigation_params.get<JS::NonnullGCPtr<NavigationParams>>()->response; response->status() != 204 && response->status() != 205) {
|
||||||
auto document = load_document(navigation_params.get<JS::NonnullGCPtr<NavigationParams>>());
|
auto document = load_document(navigation_params.get<JS::NonnullGCPtr<NavigationParams>>());
|
||||||
entry->document_state()->set_document(document);
|
entry->document_state()->set_document(document);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue