How to guard against devide by 0?

后端 未结 0 746
后悔当初
后悔当初 2021-01-07 05:11

The following code should be safe.

{% if number-of-images > 0 %}
    {% assign gap = number-of-paragraphs | divided_by: number-of-images | floor %}
{% endi         


        
相关标签:
回答
  • 消灭零回复
提交回复
热议问题