2
0
mirror of https://github.com/frappe/books.git synced 2024-11-12 16:36:27 +00:00

fix: resolve linting issues

This commit is contained in:
AbleKSaju 2024-09-30 15:08:00 +05:30
parent 301a04a638
commit ea5293bb8b

View File

@ -195,7 +195,7 @@ export abstract class Invoice extends Transactional {
if (this.isReturn) {
await this._removeLoyaltyPointEntry();
await this.reduceUsedCountOfCoupons();
this.reduceUsedCountOfCoupons();
return;
}
@ -251,11 +251,7 @@ export abstract class Invoice extends Transactional {
await this._updatePartyOutStanding();
await this._updateIsItemsReturned();
await this._removeLoyaltyPointEntry();
await this._reduceUsedCountOfCoupon();
}
async _reduceUsedCountOfCoupon() {
await this.reduceUsedCountOfCoupons();
this.reduceUsedCountOfCoupons();
}
async _removeLoyaltyPointEntry() {
@ -572,7 +568,7 @@ export abstract class Invoice extends Transactional {
await couponDoc.setAndSync({ used: (couponDoc.used as number) + 1 });
});
}
async reduceUsedCountOfCoupons() {
reduceUsedCountOfCoupons() {
if (!this.coupons?.length) {
return;
}