FEATURE Cancelling link on post card for fonds-archives (unecessary)
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
Antoine M 2026-06-08 09:43:39 +02:00
parent 0b830c7bab
commit 4481a69316

View File

@ -531,6 +531,12 @@ function carhop_get_post_card_link_according_to_post_datas($post_id, $card_args
$target = '_blank';
$text = 'Voir la notice';
break;
case 'fonds-archives':
$link = '';
$target = '_self';
$text = null;
$is_external = false;
break;
default:
$link = get_permalink($post_id) ?: '';
break;
@ -541,6 +547,6 @@ function carhop_get_post_card_link_according_to_post_datas($post_id, $card_args
'target' => $target,
'text' => $text,
'is_external' => $is_external,
'has_valid_link' => ($link !== ''),
'has_valid_link' => ! empty($link),
);
}