fix: enable gift-card creation without order_id

This commit is contained in:
Sebastian Rindom
2021-03-08 13:58:01 +01:00
parent 6a3409d239
commit 9ce935a779
2 changed files with 4 additions and 7 deletions
@@ -381,6 +381,10 @@ class SendGridService extends NotificationService {
relations: ["region", "order"],
})
if (!giftCard.order) {
return
}
const taxRate = giftCard.region.tax_rate / 100
return {