Backend changes to allow handling local-only toots not based on emoji
This commit is contained in:
parent
284a1562fb
commit
71b1d4c694
2 changed files with 4 additions and 1 deletions
|
@ -45,7 +45,8 @@ class Api::V1::StatusesController < Api::BaseController
|
|||
application: doorkeeper_token.application,
|
||||
poll: status_params[:poll],
|
||||
content_type: status_params[:content_type],
|
||||
idempotency: request.headers['Idempotency-Key'])
|
||||
idempotency: request.headers['Idempotency-Key'],
|
||||
local_only: status_params[:local_only])
|
||||
|
||||
render json: @status, serializer: @status.is_a?(ScheduledStatus) ? REST::ScheduledStatusSerializer : REST::StatusSerializer
|
||||
end
|
||||
|
@ -77,6 +78,7 @@ class Api::V1::StatusesController < Api::BaseController
|
|||
:visibility,
|
||||
:scheduled_at,
|
||||
:content_type,
|
||||
:local_only,
|
||||
media_ids: [],
|
||||
poll: [
|
||||
:multiple,
|
||||
|
|
|
@ -164,6 +164,7 @@ class PostStatusService < BaseService
|
|||
language: language_from_option(@options[:language]) || @account.user&.setting_default_language&.presence || LanguageDetector.instance.detect(@text, @account),
|
||||
application: @options[:application],
|
||||
content_type: @options[:content_type] || @account.user&.setting_default_content_type,
|
||||
local_only: @options[:local_only],
|
||||
}.compact
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in a new issue