Skip to content

Commit a50785e

Browse files
Fix session payload in sync with other clients ruby and python
1 parent e8108ac commit a50785e

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/main/java/io/appium/java_client/remote/NewAppiumSessionPayload.java

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -269,12 +269,13 @@ public void writeTo(Appendable appendable) throws IOException {
269269
json.beginObject();
270270

271271
json.name(ALWAYS_MATCH);
272-
json.write(first);
272+
getW3C().forEach(json::write);
273273

274274
json.name(FIRST_MATCH);
275275
json.beginArray();
276276
//noinspection unchecked
277-
getW3C().forEach(json::write);
277+
json.beginObject();
278+
json.endObject();
278279
json.endArray();
279280

280281
json.endObject(); // Close "capabilities" object

0 commit comments

Comments
 (0)