Use use case for `User#unban`

This commit is contained in:
Karina Kwiatek 2021-12-30 13:13:35 +01:00
parent 0659ff1f9a
commit a9392dad53
1 changed files with 1 additions and 1 deletions

View File

@ -228,7 +228,7 @@ class User < ApplicationRecord
end
def unban
self.bans.current.update!(expires_at: DateTime.now)
UseCase::User::Unban.call(id)
end
# Bans a user.