Skip to content

Commit 00d0d43

Browse files
committed
trim things
1 parent 0f4a7e6 commit 00d0d43

File tree

1 file changed

+24
-13
lines changed

1 file changed

+24
-13
lines changed

index.html

Lines changed: 24 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -2122,16 +2122,17 @@ <h2>
21222122
</li>
21232123
<li>Set <var>address</var>.<a>[[\addressLine]]</a> to the empty
21242124
frozen array, and all other <a data-lt=
2125-
"PaymentAddress slots">internal slots</a> set to the empty string.
2125+
"PaymentAddress slots">internal slots</a> to the empty string.
21262126
</li>
21272127
<li>If <var>details</var> was not passed, return
21282128
<var>address</var>.
21292129
</li>
21302130
<li>If <var>details</var>["<a>country</a>"] is present:
21312131
<ol>
2132-
<li>Let <var>country</var> be the result of <a data-cite=
2133-
"!INFRA#ascii-uppercase">ASCII uppercasing</a>
2134-
<var>details</var>["<a>country</a>"].
2132+
<li>Set <var>country</var> the result of <a>stripping leading
2133+
and trailing ASCII whitespace</a> from
2134+
<var>details</var>["<a>country</a>"] and performing
2135+
<a data-cite="!INFRA#ascii-uppercase">ASCII uppercasing</a>.
21352136
</li>
21362137
<li>If <var>country</var> is not a valid [[!ISO3166-1]] alpha-2
21372138
code, throw a <a>RangeError</a> exception.
@@ -2153,9 +2154,22 @@ <h2>
21532154
</li>
21542155
</ol>
21552156
</li>
2156-
<li>If <var>details</var>["<a>addressLine</a>"] is present, set
2157-
<var>address</var>.<a>[[\addressLine]]</a> to a new frozen array
2158-
created from <var>details</var>["<a>addressLine</a>"].
2157+
<li>Let <var>cleanAddressLines</var> be an emtpy list.
2158+
</li>
2159+
<li>If <var>details</var>["<a>addressLine</a>"] is present, then
2160+
for each <var>item</var> in
2161+
<var>details</var>["<a>addressLine</a>"]:
2162+
<ol>
2163+
<li>
2164+
<a>strip leading and trailing ASCII whitespace</a> from
2165+
<var>item</var> and append the result into
2166+
<var>cleanAddressLines</var>
2167+
</li>
2168+
</ol>
2169+
</li>
2170+
<li>
2171+
<var>Set address</var>.<a>[[\addressLine]]</a> to a new frozen
2172+
array created from <var>cleanAddressLines</var>.
21592173
</li>
21602174
<li>If <var>details</var>["<a>region</a>"] is present, <a>strip
21612175
leading and trailing ASCII whitespace</a> from
@@ -2614,12 +2628,9 @@ <h2>
26142628
<var>details</var>["<a>recipient</a>"] to the user-provided recipient
26152629
of the transaction, or to the empty string if none was provided.
26162630
</li>
2617-
<li>If "region" is not in <var>redactList</var>:
2618-
<ol>
2619-
<li>Set <var>details</var>["<a>region</a>"] to the user-provided
2620-
region, or to the empty string if none was provided.
2621-
</li>
2622-
</ol>
2631+
<li>If "region" is not in <var>redactList</var>, set
2632+
<var>details</var>["<a>region</a>"] to the user-provided region, or
2633+
to the empty string if none was provided.
26232634
</li>
26242635
<li>If "sortingCode" is not in <var>redactList</var>, set
26252636
<var>details</var>["<a>sortingCode</a>"] to the user-provided sorting

0 commit comments

Comments
 (0)