diff options
author | Jack Jennings <jack@standard-library.com> | 2017-05-30 06:16:14 -0700 |
---|---|---|
committer | Eugen Rochko <eugen@zeonfederated.com> | 2017-05-30 15:16:14 +0200 |
commit | e031fd60ad9ee492fbbda319eaeb213098898d03 (patch) | |
tree | 212e09bc3b785addd5d0c45583b4b4a3ef7042eb /app/services | |
parent | bc4fad9e22695aae04cf06ada7f1c70887028cde (diff) |
Move status reblog authorization into policy (#3425)
Diffstat (limited to 'app/services')
-rw-r--r-- | app/services/reblog_service.rb | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/app/services/reblog_service.rb b/app/services/reblog_service.rb index 9c44b1980..a3636a283 100644 --- a/app/services/reblog_service.rb +++ b/app/services/reblog_service.rb @@ -11,8 +11,7 @@ class ReblogService < BaseService def call(account, reblogged_status) reblogged_status = reblogged_status.reblog if reblogged_status.reblog? - authorize_with account, reblogged_status, :show? - raise Mastodon::NotPermittedError if reblogged_status.direct_visibility? || reblogged_status.private_visibility? + authorize_with account, reblogged_status, :reblog? reblog = account.statuses.create!(reblog: reblogged_status, text: '') |