Module: Rails::AddOns::Service::Result::Base::Succeedable

Included in:
Rails::AddOns::Service::Result::Base
Defined in:
app/services/rails/add_ons/service/result/base.rb

Instance Method Summary collapse

Instance Method Details

#failed?Boolean


22
23
24
# File 'app/services/rails/add_ons/service/result/base.rb', line 22

def failed?
  @errors.any?
end

#ok?Boolean


26
27
28
# File 'app/services/rails/add_ons/service/result/base.rb', line 26

def ok?
  success?
end

#success?Boolean


18
19
20
# File 'app/services/rails/add_ons/service/result/base.rb', line 18

def success?
  !failed?
end