fix(bundles): hide old price if no discount (#5561)

This commit is contained in:
Sergey Andrievskiy 2019-11-14 17:25:14 +03:00 committed by Sergey Andrievskiy
parent 9e85f2aab5
commit a5a535d341
4 changed files with 23 additions and 4 deletions

View file

@ -91,7 +91,7 @@ export class BundlesService {
storeUrl: `${this.STORE}/${item.handle}`,
tags: item.tags,
title: item.title,
description: (item.body_html as string).trim().replace(/^<p>/, '').replace(/<\/p>$/, ''),
description: (item.body_html as string).trim().replace(/<(?:.|\n)*?>/gm, ' ').replace(/ +/gm, ' '),
variants: item.variants.map(variant => {
return {
available: variant.available,