mirror of
https://github.com/discourse/discourse.git
synced 2025-05-24 03:36:18 +08:00
FEATURE: Site setting to display user avatars in user menu (#24514)
This commit is contained in:

committed by
GitHub

parent
e4c373194d
commit
ee05f57e2d
@ -57,6 +57,8 @@ class NotificationsController < ApplicationController
|
||||
|
||||
notifications =
|
||||
Notification.filter_inaccessible_topic_notifications(current_user.guardian, notifications)
|
||||
notifications =
|
||||
Notification.populate_acting_user(notifications) if SiteSetting.show_user_menu_avatars
|
||||
|
||||
json = {
|
||||
notifications: serialize_data(notifications, NotificationSerializer),
|
||||
@ -86,6 +88,8 @@ class NotificationsController < ApplicationController
|
||||
notifications = notifications.offset(offset).limit(limit)
|
||||
notifications =
|
||||
Notification.filter_inaccessible_topic_notifications(current_user.guardian, notifications)
|
||||
notifications =
|
||||
Notification.populate_acting_user(notifications) if SiteSetting.show_user_menu_avatars
|
||||
render_json_dump(
|
||||
notifications: serialize_data(notifications, NotificationSerializer),
|
||||
total_rows_notifications: total_rows,
|
||||
|
Reference in New Issue
Block a user