From: Eugen Rochko Date: Thu, 8 Mar 2018 07:20:49 +0000 (+0100) Subject: For now, put a "." into no-text statuses with media for backcompat (#6691) X-Git-Url: https://git.xn--scling-oua.cat.family/?a=commitdiff_plain;h=510c9049c79f4eb1e082932ff067fdb4216d1039;p=mastodon.git For now, put a "." into no-text statuses with media for backcompat (#6691) --- diff --git a/app/services/post_status_service.rb b/app/services/post_status_service.rb index df38d16a6..c91192181 100644 --- a/app/services/post_status_service.rb +++ b/app/services/post_status_service.rb @@ -22,6 +22,7 @@ class PostStatusService < BaseService media = validate_media!(options[:media_ids]) status = nil text = options.delete(:spoiler_text) if text.blank? && options[:spoiler_text].present? + text = '.' if text.blank? && !media.empty? ApplicationRecord.transaction do status = account.statuses.create!(text: text,