alias Pleroma.Activity
alias Pleroma.Notification
- alias Pleroma.User
alias Pleroma.Object
+ alias Pleroma.User
alias Pleroma.UserRelationship
alias Pleroma.Web.CommonAPI
alias Pleroma.Web.MastodonAPI.AccountView
end
end
- # This returns the notification type by activity, but both chats and statuses are in "Create" activities.
+ # This returns the notification type by activity, but both chats and statuses
+ # are in "Create" activities.
mastodon_type =
case Activity.mastodon_notification_type(activity) do
"mention" ->
# Note: :skip_relationships option being applied to _account_ rendering (here)
put_target(response, activity, reading_user, render_opts)
- "follow" ->
- response
-
"pleroma:emoji_reaction" ->
response
|> put_status(parent_activity_fn.(), reading_user, render_opts)
"pleroma:chat_mention" ->
put_chat_message(response, activity, reading_user, render_opts)
+ type when type in ["follow", "follow_request"] ->
+ response
+
_ ->
nil
end