Skip to content

Commit 5948df9

Browse files
committed
Java: Improving handling of marionette errors
1 parent 4edf929 commit 5948df9

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

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

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -253,6 +253,7 @@ public static String toState(Integer status) {
253253
}
254254

255255
public static int toStatus(String state) {
256-
return stateToStatus.get(state);
256+
Integer status = stateToStatus.get(state);
257+
return status != null ? status : UNHANDLED_ERROR;
257258
}
258259
}

0 commit comments

Comments
 (0)