Skip to content

Commit 7860dec

Browse files
Update soy test to remove deprecated {ifempty} (bazelbuild#573)
Refactor {ifempty} to explicit length() check. {ifempty} is deprecated.
1 parent 0d652b0 commit 7860dec

1 file changed

Lines changed: 6 additions & 4 deletions

File tree

java/io/bazel/rules/closure/webfiles/server/listing.soy

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -48,10 +48,12 @@
4848
<h1>Bazel Closure Rules</h1>
4949
<h3>{$label}</h3>
5050
<p>
51-
{for $path in $paths}
52-
<a href="{$path}">{$path}</a><br>
53-
{ifempty}
51+
{if $paths.length() != 0}
52+
{for $path in $paths}
53+
<a href="{$path}">{$path}</a><br>
54+
{/for}
55+
{else}
5456
No srcs found in transitive closure with path component prefix matching
5557
request path.
56-
{/for}
58+
{/if}
5759
{/template}

0 commit comments

Comments
 (0)