Skip to content

Commit a0ed021

Browse files
committed
Simplify the public suffix and registrable domain definitions
1 parent 05a5d83 commit a0ed021

File tree

1 file changed

+2
-18
lines changed

1 file changed

+2
-18
lines changed

url.bs

Lines changed: 2 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -787,17 +787,9 @@ that is included on the <cite>Public Suffix List</cite>. [[!PSL]]
787787
<ol>
788788
<li><p>If <var>host</var> is not a <a>domain</a>, then return null.
789789

790-
<li><p>Let <var>trailingDot</var> be "<code>.</code>" if <var>host</var>
791-
<a for=string>ends with</a> "<code>.</code>"; otherwise the empty string.
792-
793-
<li><p>Let <var>publicSuffix</var> be the public suffix determined by running the
790+
<li><p>Return the public suffix determined by running the
794791
<a href="https://github.com/publicsuffix/list/wiki/Format#formal-algorithm">Public Suffix List algorithm</a>
795792
with <var>host</var> as domain. [[!PSL]]
796-
797-
<li><p>Assert: <var>publicSuffix</var> is an <a>ASCII string</a> that does not
798-
<a for=string>end with</a> "<code>.</code>".
799-
800-
<li><p>Return <var>publicSuffix</var> and <var>trailingDot</var> concatenated.
801793
</ol>
802794
</div>
803795

@@ -811,17 +803,9 @@ any.
811803
<li><p>If <var>host</var>'s <a for=host>public suffix</a> is null or <var>host</var>'s
812804
<a for=host>public suffix</a> <a for=host>equals</a> <var>host</var>, then return null.
813805

814-
<li><p>Let <var>trailingDot</var> be "<code>.</code>" if <var>host</var>
815-
<a for=string>ends with</a> "<code>.</code>"; otherwise the empty string.
816-
817-
<li><p>Let <var>registrableDomain</var> be the registrable domain determined by running the
806+
<li><p>Return the registrable domain determined by running the
818807
<a href="https://github.com/publicsuffix/list/wiki/Format#formal-algorithm">Public Suffix List algorithm</a>
819808
with <var>host</var> as domain. [[!PSL]]
820-
821-
<li><p>Assert: <var>registrableDomain</var> is an <a>ASCII string</a> that does not
822-
<a for=string>end with</a> "<code>.</code>".
823-
824-
<li><p>Return <var>registrableDomain</var> and <var>trailingDot</var> concatenated.
825809
</ol>
826810
</div>
827811

0 commit comments

Comments
 (0)