Merge commit '7d9b209fe84b00eff348ea9d54905cbfffa79788' into glitch-soc/merge-upstream
Conflicts: - `app/models/form/admin_settings.rb`: Upstream changed code style change, including on a line modified by glitch-soc. Kept glitch-soc's line but with the code style change applied.
This commit is contained in:
commit
30ee7339d3
33 files changed
+591
-485
No files matched your search
@@ -25,6 +25,6 @@ class Api::V1::Accounts::NotesController < Api::BaseController
|
||||
end
|
||||
|
||||
def relationships_presenter
|
||||
AccountRelationshipsPresenter.new([@account.id], current_user.account_id)
|
||||
AccountRelationshipsPresenter.new([@account], current_user.account_id)
|
||||
end
|
||||
end
|
||||
@@ -25,6 +25,6 @@ class Api::V1::Accounts::PinsController < Api::BaseController
|
||||
end
|
||||
|
||||
def relationships_presenter
|
||||
AccountRelationshipsPresenter.new([@account.id], current_user.account_id)
|
||||
AccountRelationshipsPresenter.new([@account], current_user.account_id)
|
||||
end
|
||||
end
|
||||
@@ -5,7 +5,7 @@ class Api::V1::Accounts::RelationshipsController < Api::BaseController
|
||||
before_action :require_user!
|
||||
|
||||
def index
|
||||
@accounts = Account.where(id: account_ids).select('id')
|
||||
@accounts = Account.where(id: account_ids).select(:id, :domain)
|
||||
@accounts.merge!(Account.without_suspended) unless truthy_param?(:with_suspended)
|
||||
render json: @accounts, each_serializer: REST::RelationshipSerializer, relationships: relationships
|
||||
end
|
||||
|
||||
@@ -88,7 +88,7 @@ class Api::V1::AccountsController < Api::BaseController
|
||||
end
|
||||
|
||||
def relationships(**options)
|
||||
AccountRelationshipsPresenter.new([@account.id], current_user.account_id, **options)
|
||||
AccountRelationshipsPresenter.new([@account], current_user.account_id, **options)
|
||||
end
|
||||
|
||||
def account_params
|
||||
|
||||
@@ -12,7 +12,7 @@ class Api::V1::DirectoriesController < Api::BaseController
|
||||
private
|
||||
|
||||
def require_enabled!
|
||||
return not_found unless Setting.profile_directory
|
||||
not_found unless Setting.profile_directory
|
||||
end
|
||||
|
||||
def set_accounts
|
||||
|
||||
@@ -25,11 +25,11 @@ class Api::V1::FollowRequestsController < Api::BaseController
|
||||
private
|
||||
|
||||
def account
|
||||
Account.find(params[:id])
|
||||
@account ||= Account.find(params[:id])
|
||||
end
|
||||
|
||||
def relationships(**options)
|
||||
AccountRelationshipsPresenter.new([params[:id]], current_user.account_id, **options)
|
||||
AccountRelationshipsPresenter.new([account], current_user.account_id, **options)
|
||||
end
|
||||
|
||||
def load_accounts
|
||||
|
||||
Reference in new issue
Block a user