Merge remote-tracking branch 'remotes/origin/develop' into 1559-follow-request-notifi...
authorIvan Tashkinov <ivantashkinov@gmail.com>
Fri, 17 Apr 2020 13:23:58 +0000 (16:23 +0300)
committerIvan Tashkinov <ivantashkinov@gmail.com>
Fri, 17 Apr 2020 13:23:58 +0000 (16:23 +0300)
# Conflicts:
# CHANGELOG.md

1  2 
CHANGELOG.md
config/config.exs
lib/pleroma/user.ex
lib/pleroma/web/mastodon_api/views/notification_view.ex

diff --cc CHANGELOG.md
index b3b63ac544c00a710af945950a99079cb312e564,2239a5288e1f389771044965c2d0106fbd8e2555..3bc0bb9af185eb66f25bb35a6248cbde9400bc4e
@@@ -15,7 -12,7 +12,8 @@@ The format is based on [Keep a Changelo
  - NodeInfo: `pleroma_emoji_reactions` to the `features` list.
  - Configuration: `:restrict_unauthenticated` setting, restrict access for unauthenticated users to timelines (public and federate), user profiles and statuses.
  - New HTTP adapter [gun](https://github.com/ninenines/gun). Gun adapter requires minimum OTP version of 22.2 otherwise Pleroma won’t start. For hackney OTP update is not required.
+ - Mix task to create trusted OAuth App.
 +- Notifications: Added `follow_request` notification type (configurable, see `[:notifications, :enable_follow_request_notifications]` setting).
  <details>
    <summary>API Changes</summary>
  - Mastodon API: Support for `include_types` in `/api/v1/notifications`.
Simple merge
index ac2594417ce8c206010ae28d3a6cbf9dbfa6d6d5,896bab14021b1a228f286b3d2ec44626c5989de0..bef4679cbad9c47bc0aa83ad2c5f8ae2de47880f
@@@ -699,10 -688,8 +688,10 @@@ defmodule Pleroma.User d
    def needs_update?(_), do: true
  
    @spec maybe_direct_follow(User.t(), User.t()) :: {:ok, User.t()} | {:error, String.t()}
 +
 +  # "Locked" (self-locked) users demand explicit authorization of follow requests
    def maybe_direct_follow(%User{} = follower, %User{local: true, locked: true} = followed) do
-     follow(follower, followed, "pending")
+     follow(follower, followed, :follow_pending)
    end
  
    def maybe_direct_follow(%User{} = follower, %User{local: true} = followed) do
index 7001fd7b9f5976640603deec219578ea4b194112,734ffbf39fd909a1837b93d489088fb2087c8dd1..4da1ab67f58385e2548c1e923fb742f09afc5f7b
@@@ -111,8 -114,12 +114,9 @@@ defmodule Pleroma.Web.MastodonAPI.Notif
            put_status(response, parent_activity_fn.(), reading_user, render_opts)
  
          "move" ->
+           # 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)