Skip to content

Commit 6e7d06b

Browse files
jimevansshs96c
authored andcommitted
Null data on response should be wrapped in JSON object
In the `send a response` algorithm, when the data to be returned as the response for a command is `null`, it should be wrapped in a JSON object with a `value` property set to `null` rather than sending no body. Fixes issue #807.
1 parent 90cc746 commit 6e7d06b

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

webdriver-spec.html

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -966,9 +966,9 @@ <h3>Processing Model</h3>
966966
<dd>"<code>no-cache</code>"
967967
</dl>
968968

969-
<li><p>If <var>data</var> is not <a><code>null</code></a>, let <var>response</var>’s
970-
<a>body</a> be a JSON <a>Object</a> with a key <code>value</code>
971-
set to the <a>JSON serialization</a> of <var>data</var>.
969+
<li><p>Let <var>response</var>’s <a>body</a> be a JSON <a>Object</a> with
970+
a key <code>value</code> set to the <a>JSON serialization</a> of
971+
<var>data</var>.
972972

973973
<li><p>Let <var>response bytes</var> be the byte sequence resulting
974974
from serializing <var>response</var> according to the rules in [[!RFC7230]].

0 commit comments

Comments
 (0)