diff options
author | Claire <claire.github-309c@sitedethib.com> | 2023-03-02 17:32:38 +0100 |
---|---|---|
committer | Claire <claire.github-309c@sitedethib.com> | 2023-03-02 17:32:38 +0100 |
commit | 276c1d32d6fc857a768244c3f5d835c9c5da1747 (patch) | |
tree | 4619ffd871db93c3932cfb79f9852368096dc5b5 /app/helpers | |
parent | 6a4be4e96677eb3e1303ddcab8f8b4bea7298453 (diff) | |
parent | af578e8ce0aabdbe9c0cd3d72d6fa2cc30b7fc66 (diff) |
Merge branch 'main' into glitch-soc/merge-upstream
Diffstat (limited to 'app/helpers')
-rw-r--r-- | app/helpers/admin/announcements_helper.rb | 11 | ||||
-rw-r--r-- | app/helpers/home_helper.rb | 12 |
2 files changed, 2 insertions, 21 deletions
diff --git a/app/helpers/admin/announcements_helper.rb b/app/helpers/admin/announcements_helper.rb deleted file mode 100644 index 0c053ddec..000000000 --- a/app/helpers/admin/announcements_helper.rb +++ /dev/null @@ -1,11 +0,0 @@ -# frozen_string_literal: true - -module Admin::AnnouncementsHelper - def time_range(announcement) - if announcement.all_day? - safe_join([l(announcement.starts_at.to_date), ' - ', l(announcement.ends_at.to_date)]) - else - safe_join([l(announcement.starts_at), ' - ', l(announcement.ends_at)]) - end - end -end diff --git a/app/helpers/home_helper.rb b/app/helpers/home_helper.rb index f41104709..ea2196086 100644 --- a/app/helpers/home_helper.rb +++ b/app/helpers/home_helper.rb @@ -41,9 +41,9 @@ module HomeHelper def obscured_counter(count) if count <= 0 - 0 + '0' elsif count == 1 - 1 + '1' else '1+' end @@ -57,14 +57,6 @@ module HomeHelper end end - def optional_link_to(condition, path, options = {}, &block) - if condition - link_to(path, options, &block) - else - content_tag(:div, &block) - end - end - def sign_up_message if closed_registrations? t('auth.registration_closed', instance: site_hostname) |