Skip to content

Commit

Permalink
fix(client): new_with_connector: correctly setup session (#282)
Browse files Browse the repository at this point in the history
`Session::with_capabilities_and_connector` would issue a new session,
so we should call it in the constructor.
  • Loading branch information
Bogay authored Jan 5, 2025
1 parent 5a947bd commit af64315
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/client.rs
Original file line number Diff line number Diff line change
Expand Up @@ -67,8 +67,7 @@ impl Client {
where
C: connect::Connect + Unpin + 'static + Clone + Send + Sync,
{
let (client, wdb) = Session::create_client_and_parse_url(webdriver, connector).await?;
Session::setup_session(client, wdb, None).await
Session::with_capabilities_and_connector(webdriver, &Default::default(), connector).await
}

/// Reconnect to a previously established WebDriver session using its ID.
Expand Down

0 comments on commit af64315

Please sign in to comment.