]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
docs: newapi: Properly skip ACL entries if empty
authorPeter Krempa <pkrempa@redhat.com>
Thu, 29 Feb 2024 13:22:58 +0000 (14:22 +0100)
committerPeter Krempa <pkrempa@redhat.com>
Fri, 1 Mar 2024 11:51:56 +0000 (12:51 +0100)
The source document can contain an empty '@flags' attribute which passes
the test but generates an empty element. Check that flags is non-empty
to trigger the fallback.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Pavel Hrdina <phrdina@redhat.com>
docs/newapi.xsl

index 36bb41c8772a55a36c97ac146f2ca0e321a28fb6..51f159a2f8389e8b41f3e8b6d80b550ac20d31aa 100644 (file)
@@ -62,7 +62,7 @@
       <td><a href="../acl.html#object_{@object}"><xsl:value-of select="@object"/></a></td>
       <td><a href="../acl.html#perm_{@object}_{@perm}"><xsl:value-of select="@perm"/></a></td>
       <xsl:choose>
-        <xsl:when test="@flags">
+        <xsl:when test="@flags != ''">
           <td><xsl:value-of select="@flags"/></td>
         </xsl:when>
         <xsl:otherwise>