Browse Source

Return iso8601 date.

tags/v0.9.9
Roger Braun 6 years ago
parent
commit
d2faee01ee
1 changed files with 1 additions and 0 deletions
  1. +1
    -0
      lib/pleroma/web/mastodon_api/mastodon_api_controller.ex

+ 1
- 0
lib/pleroma/web/mastodon_api/mastodon_api_controller.ex View File

@@ -157,6 +157,7 @@ defmodule Pleroma.Web.MastodonAPI.MastodonAPIController do
notifications = Notification.for_user(user, params)
result = Enum.map(notifications, fn (%{id: id, activity: activity, inserted_at: created_at}) ->
actor = User.get_cached_by_ap_id(activity.data["actor"])
created_at = NaiveDateTime.to_iso8601(created_at)
case activity.data["type"] do
"Create" ->
%{id: id, type: "mention", created_at: created_at, account: AccountView.render("account.json", %{user: actor}), status: StatusView.render("status.json", %{activity: activity})}


Loading…
Cancel
Save