|
|
@ -22,7 +22,7 @@ class PostStatusService < BaseService
|
|
|
|
media = validate_media!(options[:media_ids])
|
|
|
|
media = validate_media!(options[:media_ids])
|
|
|
|
status = nil
|
|
|
|
status = nil
|
|
|
|
text = options.delete(:spoiler_text) if text.blank? && options[:spoiler_text].present?
|
|
|
|
text = options.delete(:spoiler_text) if text.blank? && options[:spoiler_text].present?
|
|
|
|
text = '.' if text.blank? && !media.empty?
|
|
|
|
text = '.' if text.blank? && media.present?
|
|
|
|
|
|
|
|
|
|
|
|
ApplicationRecord.transaction do
|
|
|
|
ApplicationRecord.transaction do
|
|
|
|
status = account.statuses.create!(text: text,
|
|
|
|
status = account.statuses.create!(text: text,
|
|
|
|