@if (Products != null && Products.Count != 0 && currentProduct != Products.Count && currentProduct >= 0) {
- @for(int i = 0; i < Products[currentProduct].ImagesUrls.Length && i < 3; i++) {
- string image = Products[currentProduct].ImagesUrls[i];
- if (currentImage == image) {
-

+ @if(Products[currentProduct].ImagesUrls.Length > 0) {
+ @for(int i = 0; i < Products[currentProduct].ImagesUrls.Length && i < 3; i++) {
+ string image = Products[currentProduct].ImagesUrls[i];
+ if (currentImage == image) {
+

+ }
}
+

ShowNextImage(currentImage))"/>
+

ShowPreviousImage(currentImage))"/>
+ }
+ else
+ {
+
![product image]()
}
-

ChangeImage(currentImage))"/>
-

ChangeImage(currentImage))"/>
+
@for (var i = 0; i < Products[currentProduct].ImagesUrls.Length && i < 3; i++) {
@@ -99,10 +78,6 @@
- if(!isProductsNull) {
- isProductsNull = true;
- StateHasChanged();
- }
}
else {