Skip to content

Commit 0813b60

Browse files
authored
prioritise image hide over other image types (#13370)
1 parent 205eba0 commit 0813b60

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

dotcom-rendering/src/model/enhanceCards.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -87,15 +87,14 @@ const decideUrl = (trail: FESupportingContent | FEFrontCard) => {
8787
};
8888

8989
const decideImage = (trail: FEFrontCard) => {
90+
if (trail.display.imageHide) return undefined;
9091
if (
9192
trail.type === 'LinkSnap' ||
9293
trail.properties.image?.type === 'Replace'
9394
) {
9495
return trail.properties.image?.item.imageSrc;
9596
}
9697

97-
if (trail.display.imageHide) return undefined;
98-
9998
if (trail.properties.isCrossword && trail.properties.maybeContentId) {
10099
return `https://api.nextgen.guardianapps.co.uk/${trail.properties.maybeContentId}.svg`;
101100
}

0 commit comments

Comments
 (0)