Merge branch 'main' into glitch-soc/merge-upstream
Conflicts: - `app/controllers/admin/base_controller.rb`: Minor conflict caused by glitch-soc's theming system. - `app/javascript/mastodon/initial_state.js`: Minor conflict caused by glitch-soc making use of max_toot_chars. - `app/models/form/admin_settings.rb`: Minor conflict caused by glitch-soc's theming system. - `app/models/trends.rb`: Minor conflict caused by glitch-soc having more granular notification settings for trends. - `app/views/admin/accounts/index.html.haml`: Minor conflict caused by glitch-soc's theming system. - `app/views/admin/instances/show.html.haml`: Minor conflict caused by glitch-soc's theming system. - `app/views/layouts/application.html.haml`: Minor conflict caused by glitch-soc's theming system. - `app/views/settings/preferences/notifications/show.html.haml`: Minor conflict caused by glitch-soc having more granular notification settings for trends. - `config/navigation.rb`: Minor conflict caused by glitch-soc having additional navigation items for the theming system while upstream slightly changed every line.
This commit is contained in:
@ -61,11 +61,11 @@ class AccountSearchService < BaseService
|
||||
end
|
||||
|
||||
def advanced_search_results
|
||||
Account.advanced_search_for(terms_for_query, account, limit_for_non_exact_results, options[:following], offset)
|
||||
Account.advanced_search_for(terms_for_query, account, limit: limit_for_non_exact_results, following: options[:following], offset: offset)
|
||||
end
|
||||
|
||||
def simple_search_results
|
||||
Account.search_for(terms_for_query, limit_for_non_exact_results, offset)
|
||||
Account.search_for(terms_for_query, limit: limit_for_non_exact_results, offset: offset)
|
||||
end
|
||||
|
||||
def from_elasticsearch
|
||||
|
@ -22,7 +22,7 @@ class AppealService < BaseService
|
||||
end
|
||||
|
||||
def notify_staff!
|
||||
User.staff.includes(:account).each do |u|
|
||||
User.those_who_can(:manage_appeals).includes(:account).each do |u|
|
||||
AdminMailer.new_appeal(u.account, @appeal).deliver_later if u.allows_appeal_emails?
|
||||
end
|
||||
end
|
||||
|
@ -17,7 +17,7 @@ class BootstrapTimelineService < BaseService
|
||||
end
|
||||
|
||||
def notify_staff!
|
||||
User.staff.includes(:account).find_each do |user|
|
||||
User.those_who_can(:manage_users).includes(:account).find_each do |user|
|
||||
LocalNotificationWorker.perform_async(user.account_id, @source_account.id, 'Account', 'admin.sign_up')
|
||||
end
|
||||
end
|
||||
|
@ -76,7 +76,7 @@ class NotifyService < BaseService
|
||||
end
|
||||
|
||||
def from_staff?
|
||||
@notification.from_account.local? && @notification.from_account.user.present? && @notification.from_account.user.staff?
|
||||
@notification.from_account.local? && @notification.from_account.user.present? && @notification.from_account.user_role&.overrides?(@recipient.user_role)
|
||||
end
|
||||
|
||||
def optional_non_following_and_direct?
|
||||
|
@ -38,7 +38,7 @@ class ReportService < BaseService
|
||||
def notify_staff!
|
||||
return if @report.unresolved_siblings?
|
||||
|
||||
User.staff.includes(:account).each do |u|
|
||||
User.those_who_can(:manage_reports).includes(:account).each do |u|
|
||||
LocalNotificationWorker.perform_async(u.account_id, @report.id, 'Report', 'admin.report')
|
||||
AdminMailer.new_report(u.account, @report).deliver_later if u.allows_report_emails?
|
||||
end
|
||||
|
Reference in New Issue
Block a user