]> cat aescling's git repositories - mastodon.git/commitdiff
Merge branch 'main' into glitch-soc/merge-upstream
authorClaire <claire.github-309c@sitedethib.com>
Tue, 8 Feb 2022 17:23:53 +0000 (18:23 +0100)
committerClaire <claire.github-309c@sitedethib.com>
Tue, 8 Feb 2022 17:23:53 +0000 (18:23 +0100)
1  2 
Gemfile
Gemfile.lock
app/lib/activitypub/activity/create.rb
app/models/user.rb
app/services/post_status_service.rb
app/views/admin/follow_recommendations/show.html.haml
app/views/settings/preferences/other/show.html.haml

diff --cc Gemfile
Simple merge
diff --cc Gemfile.lock
Simple merge
Simple merge
index 9d26e0f5bf0c0cbf61ad22fde178de71ce46efd9,b3bc4a0a29efbd061e3052019d1dfdd37583fe3d..c5061dd635c2d90eb5a506b01e8602ff3dde26ca
@@@ -174,9 -162,8 +171,9 @@@ class PostStatusService < BaseServic
        sensitive: @sensitive,
        spoiler_text: @options[:spoiler_text] || '',
        visibility: @visibility,
-       language: language_from_option(@options[:language]) || @account.user&.setting_default_language&.presence || LanguageDetector.instance.detect(@text, @account),
+       language: valid_locale_or_nil(@options[:language].presence || @account.user&.preferred_posting_language || I18n.default_locale),
        application: @options[:application],
 +      content_type: @options[:content_type] || @account.user&.setting_default_content_type,
        rate_limit: @options[:with_rate_limit],
      }.compact
    end