Skip to content

Commit d8a2a4e

Browse files
committed
Resolves #492 Product details page: unnecessary leading comma in label "Free Shipping" (below price)
1 parent 068e723 commit d8a2a4e

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

src/Presentation/SmartStore.Web/Controllers/CatalogHelper.cs

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1148,10 +1148,9 @@ public ProductDetailsModel PrepareProductDetailModel(
11481148

11491149
if (!product.IsShipEnabled || (addShippingPrice == 0 && product.IsFreeShipping))
11501150
{
1151-
model.LegalInfo += "{0} {1}, {2}".FormatInvariant(
1152-
product.IsTaxExempt ? "" : taxInfo,
1153-
product.IsTaxExempt ? "" : defaultTaxRate,
1154-
T("Common.FreeShipping"));
1151+
model.LegalInfo += product.IsTaxExempt
1152+
? T("Common.FreeShipping")
1153+
: "{0} {1}, {2}".FormatInvariant(taxInfo, defaultTaxRate, T("Common.FreeShipping"));
11551154
}
11561155
else
11571156
{
@@ -1174,6 +1173,8 @@ public ProductDetailsModel PrepareProductDetailModel(
11741173
}
11751174
}
11761175

1176+
model.LegalInfo = model.LegalInfo.TrimSafe();
1177+
11771178
var dimension = _measureService.GetMeasureDimensionById(_measureSettings.BaseDimensionId)?.SystemKeyword ?? string.Empty;
11781179

11791180
model.WeightValue = product.Weight;

0 commit comments

Comments
 (0)