Skip to content

Saleor Core: the high performance, composable, headless commerce API.

Fix translated fields counting

dominik-zeglen8a12f8741a25
diff --git a/saleor/static/dashboard-next/translations/views/TranslationsEntities.tsx b/saleor/static/dashboard-next/translations/views/TranslationsEntities.tsx
index e5b3d76b5c..b2b80cbc9e 100644
--- a/saleor/static/dashboard-next/translations/views/TranslationsEntities.tsx
+++ b/saleor/static/dashboard-next/translations/views/TranslationsEntities.tsx
@@ -114,7 +114,8 @@ const TranslationsEntities: React.FC<TranslationsEntitiesProps> = ({
node.translation.seoDescription,
node.translation.seoTitle
].reduce(
- (acc, field) => acc + (field !== null ? 1 : 0)
+ (acc, field) => acc + (field !== null ? 1 : 0),
+ 0
)
: 0,
max: 4
@@ -165,7 +166,8 @@ const TranslationsEntities: React.FC<TranslationsEntitiesProps> = ({
node.translation.seoDescription,
node.translation.seoTitle
].reduce(
- (acc, field) => acc + (field !== null ? 1 : 0)
+ (acc, field) => acc + (field !== null ? 1 : 0),
+ 0
)
: 0,
max: 4
@@ -216,7 +218,8 @@ const TranslationsEntities: React.FC<TranslationsEntitiesProps> = ({
node.translation.seoDescription,
node.translation.seoTitle
].reduce(
- (acc, field) => acc + (field !== null ? 1 : 0)
+ (acc, field) => acc + (field !== null ? 1 : 0),
+ 0
)
: 0,
max: 4