Skip to content

Commit

Permalink
Merge pull request #2536 from resilient-tech/mergify/bp/version-15-ho…
Browse files Browse the repository at this point in the history
…tfix/pr-2530

fix: Ensure List is Not Empty (backport #2530)
  • Loading branch information
mergify[bot] authored Aug 22, 2024
2 parents a4488ca + e336735 commit b82b334
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,8 @@ def set_taxes(doc):
.orderby(sales_tax_template.modified, order=Order.desc)
.limit(1)
.run(pluck=True)
)[0] or 0
)
rate = rate[0] if rate else 0

tax_types = ("igst",)
if not is_inter_state_supply(doc):
Expand Down

0 comments on commit b82b334

Please sign in to comment.