mirror of
https://github.com/Retrospring/retrospring.git
synced 2025-02-01 01:39:08 +01:00
17 lines
No EOL
333 B
Ruby
17 lines
No EOL
333 B
Ruby
# frozen_string_literal: true
|
|
|
|
require 'use_case/base'
|
|
|
|
module UseCase
|
|
module User
|
|
class Unban < UseCase::Base
|
|
param :target_user_id, type: Types::Coercible::Integer
|
|
|
|
def call
|
|
UserBan.current.where(user_id: target_user_id).update_all(
|
|
expires_at: DateTime.now
|
|
)
|
|
end
|
|
end
|
|
end
|
|
end |