Merge pull request #806 from kmycode/kb-draft-5.23-lts
Release: 5.23 LTS
This commit is contained in:
commit
4e94e72911
5 changed files with 24 additions and 7 deletions
|
@ -2,7 +2,13 @@
|
|||
|
||||
All notable changes to this project will be documented in this file.
|
||||
|
||||
## |4.2.11] - 2024-08-16
|
||||
## [4.2.12] - 2024-08-19
|
||||
|
||||
### Fixed
|
||||
|
||||
- Fix broken notifications for mentions from local moderators ([ClearlyClaire](https://github.com/mastodon/mastodon/pull/31484))
|
||||
|
||||
## [4.2.11] - 2024-08-16
|
||||
|
||||
### Added
|
||||
|
||||
|
|
|
@ -89,7 +89,7 @@ class NotifyService < BaseService
|
|||
|
||||
def from_staff?
|
||||
sender = @notification.from_account
|
||||
sender.local? && sender.user.present? && sender.user_role&.overrides?(@recipient.user_role) && @sender.user_role&.highlighted? && sender.user_role&.can?(*UserRole::Flags::CATEGORIES[:moderation])
|
||||
sender.local? && sender.user.present? && sender.user_role&.overrides?(@recipient.user_role) && sender.user_role&.highlighted? && sender.user_role&.can?(*UserRole::Flags::CATEGORIES[:moderation].map(&:to_sym))
|
||||
end
|
||||
|
||||
def optional_non_following_and_direct?
|
||||
|
|
|
@ -56,7 +56,7 @@ services:
|
|||
|
||||
web:
|
||||
build: .
|
||||
image: ghcr.io/mastodon/mastodon:v4.2.11
|
||||
image: ghcr.io/mastodon/mastodon:v4.2.12
|
||||
restart: always
|
||||
env_file: .env.production
|
||||
command: bash -c "rm -f /mastodon/tmp/pids/server.pid; bundle exec rails s -p 3000"
|
||||
|
@ -77,7 +77,7 @@ services:
|
|||
|
||||
streaming:
|
||||
build: .
|
||||
image: ghcr.io/mastodon/mastodon:v4.2.11
|
||||
image: ghcr.io/mastodon/mastodon:v4.2.12
|
||||
restart: always
|
||||
env_file: .env.production
|
||||
command: node ./streaming
|
||||
|
@ -95,7 +95,7 @@ services:
|
|||
|
||||
sidekiq:
|
||||
build: .
|
||||
image: ghcr.io/mastodon/mastodon:v4.2.11
|
||||
image: ghcr.io/mastodon/mastodon:v4.2.12
|
||||
restart: always
|
||||
env_file: .env.production
|
||||
command: bundle exec sidekiq
|
||||
|
|
|
@ -9,7 +9,7 @@ module Mastodon
|
|||
end
|
||||
|
||||
def kmyblue_minor
|
||||
22
|
||||
23
|
||||
end
|
||||
|
||||
def kmyblue_flag
|
||||
|
@ -25,7 +25,7 @@ module Mastodon
|
|||
end
|
||||
|
||||
def patch
|
||||
11
|
||||
12
|
||||
end
|
||||
|
||||
def default_prerelease
|
||||
|
|
|
@ -18,6 +18,17 @@ RSpec.describe NotifyService, type: :service do
|
|||
expect { subject }.to_not change(Notification, :count)
|
||||
end
|
||||
|
||||
context 'when the sender is a local moderator' do
|
||||
let(:sender) { Fabricate(:user, role: UserRole.find_by(name: 'Admin')).account }
|
||||
let(:type) { :mention }
|
||||
let(:activity) { Fabricate(:mention, account: recipient, status: Fabricate(:status, account: sender)) }
|
||||
|
||||
it 'does notify when the sender is blocked' do
|
||||
recipient.block!(sender)
|
||||
expect { subject }.to change(Notification, :count).by(1)
|
||||
end
|
||||
end
|
||||
|
||||
it 'does not notify when sender is muted with hide_notifications' do
|
||||
recipient.mute!(sender, notifications: true)
|
||||
expect { subject }.to_not change(Notification, :count)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue