Skip to content

Commit fa0bed6

Browse files
committed
Attempt to spam in session id if none found from a command
1 parent 4c1f0a1 commit fa0bed6

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

java/client/src/org/openqa/selenium/remote/HttpCommandExecutor.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -165,6 +165,10 @@ public Response execute(Command command) throws IOException {
165165
String sessionId = HttpSessionId.getSessionId(httpResponse.getTargetHost());
166166
response.setSessionId(sessionId);
167167
}
168+
if (response.getSessionId() == null) {
169+
// Spam in the session id from the request
170+
response.setSessionId(command.getSessionId().toString());
171+
}
168172
if (QUIT.equals(command.getName())) {
169173
client.close();
170174
}

0 commit comments

Comments
 (0)