Skip payment process if item is free to borrow
This commit is contained in:
@@ -92,8 +92,8 @@ class RefundService {
|
||||
};
|
||||
}
|
||||
|
||||
// Check payment status
|
||||
if (rental.paymentStatus !== "paid") {
|
||||
// Check payment status - allow cancellation for both paid and free rentals
|
||||
if (rental.paymentStatus !== "paid" && rental.paymentStatus !== "not_required") {
|
||||
return {
|
||||
canCancel: false,
|
||||
reason: "Cannot cancel rental that hasn't been paid",
|
||||
|
||||
Reference in New Issue
Block a user