Class: Operto::StaffTasks::Destroy
- Inherits:
-
Object
- Object
- Operto::StaffTasks::Destroy
- Includes:
- Operation
- Defined in:
- lib/operto/staff_tasks/destroy.rb,
sig/operto.rbs
Instance Method Summary collapse
Methods included from Operation
Instance Method Details
#call(staff_task_id:) ⇒ ::Dry::Monads::Result[bool]
7 8 9 10 11 12 13 14 |
# File 'lib/operto/staff_tasks/destroy.rb', line 7 def call(staff_task_id:) validate_arguments!(staff_task_id) response = Operto::Client.connection.delete("stafftasks/#{staff_task_id}") Operto::Client.handle_response(response) rescue StandardError => e Failure(e) end |