From f844c4ba13231a76ac163c773ac4ffeb8268c81a Mon Sep 17 00:00:00 2001 From: Alex Gleason Date: Tue, 8 Nov 2022 17:23:41 -0600 Subject: [PATCH] ActivityDraft: detect language from content_html so it can strip links --- lib/pleroma/web/common_api/activity_draft.ex | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/pleroma/web/common_api/activity_draft.ex b/lib/pleroma/web/common_api/activity_draft.ex index fdc9999f55..dc7b4c6097 100644 --- a/lib/pleroma/web/common_api/activity_draft.ex +++ b/lib/pleroma/web/common_api/activity_draft.ex @@ -236,7 +236,7 @@ defp sensitive(draft) do defp language(draft) do language = Utils.get_valid_language(draft.params[:language]) || - LanguageDetector.detect(draft.full_payload) + LanguageDetector.detect(draft.content_html <> " " <> draft.summary) %__MODULE__{draft | language: language} end