fix error

This commit is contained in:
邱博亞 2023-04-08 23:39:54 +08:00
parent 142300523c
commit 28b9abfd24
1 changed files with 34 additions and 36 deletions

View File

@ -74,7 +74,6 @@ class BulletinFeed
if tmp_enable_annc_dept
annc_depts = annc_depts_translations[I18n.default_locale.to_s] rescue []
end
if !bf.nil?
tags = bf.tag_ids
categories = bf.category_ids
if !(categories.empty? && tags.empty?)
@ -109,9 +108,8 @@ class BulletinFeed
announcements = anns_before_filter.to_a
end
else
anns_before_filter = Bulletin.is_approved_and_show
announcements = []
end
anns_before_filter = Bulletin.can_display_and_sorted
announcements = anns_before_filter.to_a
end
all_anns = []
tag_ids = []