1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 18:27:35 +00:00

WebDriver: Remove active sessions from the close-the-session AO

These steps now have more than one caller; specifically, they may be
called from the Delete Session and Close Window endpoints. The session
was only removed from the active session map for the former endpoint.

Instead, let's more accurately handle removing the session where the
spec tells us to, so that all callers properly perform this step.
This commit is contained in:
Timothy Flynn 2023-03-07 10:46:14 -05:00 committed by Linus Groh
parent a0992c7731
commit 12015a4db6
3 changed files with 2 additions and 15 deletions

View file

@ -97,7 +97,7 @@ Web::WebDriver::Response Session::stop()
web_content_connection().close_session();
// 2. Remove the current session from active sessions.
// NOTE: Handled by WebDriver::Client.
m_client->close_session(session_id());
// 3. Perform any implementation-specific cleanup steps.
if (m_browser_pid.has_value()) {