From fd9e423076b6b9c3376987f80f96b66e2758425d Mon Sep 17 00:00:00 2001 From: sdarbinyan Date: Mon, 29 Jun 2026 23:22:00 +0400 Subject: [PATCH] error handle --- src/app/pages/cart/cart.component.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/app/pages/cart/cart.component.ts b/src/app/pages/cart/cart.component.ts index b1cb789..2c6c939 100644 --- a/src/app/pages/cart/cart.component.ts +++ b/src/app/pages/cart/cart.component.ts @@ -5,7 +5,7 @@ import { FormsModule } from '@angular/forms'; import { DomSanitizer, SafeResourceUrl } from '@angular/platform-browser'; import { CartService, ApiService, LanguageService, AuthService } from '../../services'; import { Item, CartItem, DeliveryOption } from '../../models'; -import { interval, of, Subscription } from 'rxjs'; +import { EMPTY, interval, of, Subscription } from 'rxjs'; import { catchError, exhaustMap, take, timeout } from 'rxjs/operators'; import { DeliverySelectorComponent } from '../../components/delivery-selector/delivery-selector.component'; import { EmptyCartIconComponent } from '../../components/empty-cart-icon/empty-cart-icon.component'; @@ -290,7 +290,8 @@ export class CartComponent implements OnDestroy { timeout(8000), catchError((err) => { console.error('Error checking payment status:', err); - return of(null); + this.setPaymentError(); + return EMPTY; }) ); })