From: href Date: Tue, 18 Dec 2018 14:32:41 +0000 (+0100) Subject: Twitter ActivityView: fix crash when activity content is nil X-Git-Url: https://git.squeep.com/?a=commitdiff_plain;h=f58f20abbb761f652dbc6b44d213ebe90e305899;p=akkoma Twitter ActivityView: fix crash when activity content is nil --- diff --git a/lib/pleroma/web/twitter_api/views/activity_view.ex b/lib/pleroma/web/twitter_api/views/activity_view.ex index 91d086740..bc90a1cd4 100644 --- a/lib/pleroma/web/twitter_api/views/activity_view.ex +++ b/lib/pleroma/web/twitter_api/views/activity_view.ex @@ -245,9 +245,11 @@ defmodule Pleroma.Web.TwitterAPI.ActivityView do |> Formatter.emojify(object["emoji"]) text = - content - |> String.replace(~r//, "\n") - |> HTML.strip_tags() + if content do + content + |> String.replace(~r//, "\n") + |> HTML.strip_tags() + end reply_parent = Activity.get_in_reply_to_activity(activity)