From 675ec1a0adf9b179c9b5fe407f7926c94266dd69 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Fri, 27 Sep 2024 04:18:42 -0400 Subject: [PATCH] Only show recently used tags hint when they are present (#32120) --- app/helpers/settings_helper.rb | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/app/helpers/settings_helper.rb b/app/helpers/settings_helper.rb index 64f2ad70a..fd631ce92 100644 --- a/app/helpers/settings_helper.rb +++ b/app/helpers/settings_helper.rb @@ -10,16 +10,17 @@ module SettingsHelper end def featured_tags_hint(recently_used_tags) - safe_join( - [ - t('simple_form.hints.featured_tag.name'), - safe_join( - links_for_featured_tags(recently_used_tags), - ', ' - ), - ], - ' ' - ) + recently_used_tags.present? && + safe_join( + [ + t('simple_form.hints.featured_tag.name'), + safe_join( + links_for_featured_tags(recently_used_tags), + ', ' + ), + ], + ' ' + ) end def session_device_icon(session)