We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 2770e3a commit 0020080Copy full SHA for 0020080
java/server/src/org/openqa/selenium/remote/server/rest/Responses.java
@@ -84,7 +84,7 @@ public static Response failure(
84
85
if (reason != null) {
86
JsonObject json = new Json().toJsonElement(reason).getAsJsonObject();
87
- json.addProperty("screen", screenshot.orElse(null));
+ screenshot.ifPresent(screen -> json.addProperty("screen", screen));
88
response.setValue(json);
89
}
90
return response;
0 commit comments