Skip to content

Commit 7f3e3b6

Browse files
authored
Editorial: only care about the empty string when beStrict is false
VerifyDnsLength will take care of it otherwise. (See #497 for additional context.)
1 parent c3d173f commit 7f3e3b6

File tree

1 file changed

+20
-11
lines changed

1 file changed

+20
-11
lines changed

url.bs

Lines changed: 20 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -917,20 +917,29 @@ concepts.
917917
<li><p>If <var>result</var> is a failure value, <a>domain-to-ASCII</a> <a>validation error</a>,
918918
return failure.
919919

920-
<li><p>If <var>result</var> is the empty string, <a>domain-to-ASCII</a> <a>validation error</a>,
921-
return failure.
922-
923920
<li>
924-
<p>If <var>beStrict</var> is false and <var>result</var> contains a
925-
<a>forbidden domain code point</a>, <a>domain-invalid-code-point</a> <a>validation error</a>,
926-
return failure.
921+
<p>If <var>beStrict</var> is false:
922+
923+
<ol>
924+
<li><p>If <var>result</var> is the empty string, <a>domain-to-ASCII</a> <a>validation error</a>,
925+
return failure.
927926

928-
<p class=note>Due to web compatibility and compatibility with non-DNS-based systems the
929-
<a>forbidden domain code points</a> are a subset of those disallowed when <i>UseSTD3ASCIIRules</i>
930-
is true. See also <a href="https://github.com/whatwg/url/issues/397">issue #397</a>.
927+
<li>
928+
<p>If <var>result</var> contains a <a>forbidden domain code point</a>,
929+
<a>domain-invalid-code-point</a> <a>validation error</a>, return failure.
930+
931+
<p class=note>Due to web compatibility and compatibility with non-DNS-based systems the
932+
<a>forbidden domain code points</a> are a subset of those disallowed when
933+
<i>UseSTD3ASCIIRules</i> is true. See also
934+
<a href="https://github.com/whatwg/url/issues/397">issue #397</a>.
935+
</ol>
936+
937+
<li>
938+
<p><a for=/>Assert</a>: <var>result</var> is not the empty string and does not contain a
939+
<a>forbidden domain code point</a>.
931940

932-
<li><p><a for=/>Assert</a>: <var>result</var> does not contain a
933-
<a>forbidden domain code point</a>.
941+
<p class=note><cite>Unicode IDNA Compatibility Processing</cite> guarantees this holds when
942+
<var>beStrict</var> is true. [[UTS46]]
934943

935944
<li><p>Return <var>result</var>.
936945
</ol>

0 commit comments

Comments
 (0)