projects
/
akkoma
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Add tests for fetch_follow_information_for_user and check object type
[akkoma]
/
lib
/
pleroma
/
web
/
activity_pub
/
visibility.ex
diff --git
a/lib/pleroma/web/activity_pub/visibility.ex
b/lib/pleroma/web/activity_pub/visibility.ex
index 93b50ee473b7cd9a4e27fb51105ee6efa85c42a0..9908a2e75816151e7d203b7736a657a952230a5a 100644
(file)
--- a/
lib/pleroma/web/activity_pub/visibility.ex
+++ b/
lib/pleroma/web/activity_pub/visibility.ex
@@
-1,3
+1,7
@@
+# Pleroma: A lightweight social networking server
+# Copyright © 2017-2019 Pleroma Authors <https://pleroma.social/>
+# SPDX-License-Identifier: AGPL-3.0-only
+
defmodule Pleroma.Web.ActivityPub.Visibility do
alias Pleroma.Activity
alias Pleroma.Object
defmodule Pleroma.Web.ActivityPub.Visibility do
alias Pleroma.Activity
alias Pleroma.Object
@@
-66,6
+70,9
@@
defmodule Pleroma.Web.ActivityPub.Visibility do
Enum.any?(to, &String.contains?(&1, "/followers")) ->
"private"
Enum.any?(to, &String.contains?(&1, "/followers")) ->
"private"
+ object.data["directMessage"] == true ->
+ "direct"
+
length(cc) > 0 ->
"private"
length(cc) > 0 ->
"private"