about summary refs log tree commit diff
path: root/app/models
diff options
context:
space:
mode:
authorEugen Rochko <eugen@zeonfederated.com>2018-08-23 23:26:29 +0200
committerGitHub <noreply@github.com>2018-08-23 23:26:29 +0200
commit2f34b747b3f765a37d7b23e70de42005c0b62f58 (patch)
tree4fbfe29446c9ebdfe8a072ba07a71218613eb32f /app/models
parent9d58daac6c860b599f8c266b8bb10c6170220dd3 (diff)
Allow mods to disable login, improve message when login disabled (#8329)
* Allow moderators to disable/enable login

* Instead of rejecting login, show forbidden error when login disabled

Avoid confusion because when login is rejected, the message is that
the account is not activated, which is wrong.

* Fix tests
Diffstat (limited to 'app/models')
-rw-r--r--app/models/user.rb4
1 files changed, 0 insertions, 4 deletions
diff --git a/app/models/user.rb b/app/models/user.rb
index a2cf2565f..75b7e9e7c 100644
--- a/app/models/user.rb
+++ b/app/models/user.rb
@@ -216,10 +216,6 @@ class User < ApplicationRecord
     save!
   end
 
-  def active_for_authentication?
-    super && !disabled?
-  end
-
   def setting_default_privacy
     settings.default_privacy || (account.locked? ? 'private' : 'public')
   end