[gi-docgen/class-methods: 2/2] template: Fix off-by-one error in the class method arguments




commit a3e11fa18e781eb393e0fab204584828a33df673
Author: Emmanuele Bassi <ebassi gnome org>
Date:   Wed Aug 4 23:42:08 2021 +0100

    template: Fix off-by-one error in the class method arguments
    
    The arguments array does not contain the instance argument, which means
    it starts from zero.

 gidocgen/templates/basic/class_method.html | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/gidocgen/templates/basic/class_method.html b/gidocgen/templates/basic/class_method.html
index 9337586..51d1148 100644
--- a/gidocgen/templates/basic/class_method.html
+++ b/gidocgen/templates/basic/class_method.html
@@ -91,7 +91,7 @@ SPDX-License-Identifier: Apache-2.0 OR GPL-3.0-or-later
       {% endif %}
     </div>
 
-    {% if class_method.arguments|length > 1 %}
+    {% if class_method.arguments|length != 0 %}
     <div class="parameters toggle-wrapper">
       <h4 id="parameters">
         Parameters


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]