projects
/
akkoma
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge branch 'feature/admin-api/support-token-header' into 'develop'
[akkoma]
/
lib
/
pleroma
/
user.ex
diff --git
a/lib/pleroma/user.ex
b/lib/pleroma/user.ex
index f8c2db1e1ebc3b1128c288db28f2229970d1c779..fcb1d5143942bc7738aff01ca8ecf70ca7166181 100644
(file)
--- a/
lib/pleroma/user.ex
+++ b/
lib/pleroma/user.ex
@@
-124,6
+124,9
@@
defmodule Pleroma.User do
timestamps()
end
timestamps()
end
+ @doc "Returns if the user should be allowed to authenticate"
+ def auth_active?(%User{deactivated: true}), do: false
+
def auth_active?(%User{confirmation_pending: true}),
do: !Pleroma.Config.get([:instance, :account_activation_required])
def auth_active?(%User{confirmation_pending: true}),
do: !Pleroma.Config.get([:instance, :account_activation_required])