This commit is contained in:
2025-11-23 11:41:01 +03:30
parent 969ff6a163
commit f98920001f
@@ -67,8 +67,8 @@ export class RestaurantPaymentMethodService {
); );
} }
async findByPaymentMethod(restPaymentMethodId: string): Promise<RestaurantPaymentMethod[]> { async findByPaymentMethod(restPaymentMethodId: string): Promise<RestaurantPaymentMethod | null> {
return this.restaurantPaymentMethodRepository.find( return this.restaurantPaymentMethodRepository.findOneOrFail(
{ id: restPaymentMethodId }, { id: restPaymentMethodId },
{ populate: ['restaurant', 'paymentMethod'] }, { populate: ['restaurant', 'paymentMethod'] },
); );