Commit 963d5774 authored by Sachin Joshi's avatar Sachin Joshi

fix the status notification with special char

parent 7fcbda70
......@@ -289,7 +289,7 @@ defmodule Pleroma.Web.TwitterAPI.ActivityView do
"uri" =>["id"],
"user" => UserView.render("show.json", %{user: user, for: opts[:for]}),
"statusnet_html" => html,
"text" => text,
"text" => HtmlEntities.decode(text),
"is_local" => activity.local,
"is_post_verb" => true,
"created_at" => created_at,
......@@ -371,4 +371,14 @@ defmodule Pleroma.Web.TwitterAPI.ActivityViewTest do
assert length(result["attachments"]) == 1
assert result["summary"] == "Friday Night"
test "special characters are not escaped in text field for status created" do
text = "<3 is on the way"
{:ok, activity} =, %{"status" => text})
result = ActivityView.render("activity.json", activity: activity)
assert result["text"] == text
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment