Sha256: 4d25a4f1626fb17a362a599899d6bb6faf9c68490294eb436bd04b6e73099c5b

Contents?: true

Size: 191 Bytes

Versions: 76

Compression:

Stored size: 191 Bytes

Contents

# require "eitil_core/safe_executions/safe_call"

Kernel.module_eval do

  def safe_call(*args, return_value: nil, &block)
    block.call self, *args
    rescue
      return_value
  end

end

Version data entries

76 entries across 76 versions & 1 rubygems

Version Path
eitil-1.1.28 eitil_core/lib/eitil_core/safe_executions/safe_call.rb
eitil-1.1.27 eitil_core/lib/eitil_core/safe_executions/safe_call.rb
eitil-1.1.26 eitil_core/lib/eitil_core/safe_executions/safe_call.rb
eitil-1.1.25 eitil_core/lib/eitil_core/safe_executions/safe_call.rb
eitil-1.1.24 eitil_core/lib/eitil_core/safe_executions/safe_call.rb
eitil-1.1.23 eitil_core/lib/eitil_core/safe_executions/safe_call.rb
eitil-1.1.22 eitil_core/lib/eitil_core/safe_executions/safe_call.rb
eitil-1.1.21 eitil_core/lib/eitil_core/safe_executions/safe_call.rb
eitil-1.1.20 eitil_core/lib/eitil_core/safe_executions/safe_call.rb
eitil-1.1.19 eitil_core/lib/eitil_core/safe_executions/safe_call.rb
eitil-1.1.18 eitil_core/lib/eitil_core/safe_executions/safe_call.rb
eitil-1.1.17 eitil_core/lib/eitil_core/safe_executions/safe_call.rb
eitil-1.1.16 eitil_core/lib/eitil_core/safe_executions/safe_call.rb
eitil-1.1.15 eitil_core/lib/eitil_core/safe_executions/safe_call.rb
eitil-1.1.14 eitil_core/lib/eitil_core/safe_executions/safe_call.rb
eitil-1.1.13 eitil_core/lib/eitil_core/safe_executions/safe_call.rb
eitil-1.1.12 eitil_core/lib/eitil_core/safe_executions/safe_call.rb
eitil-1.1.11 eitil_core/lib/eitil_core/safe_executions/safe_call.rb
eitil-1.1.10 eitil_core/lib/eitil_core/safe_executions/safe_call.rb
eitil-1.1.9 eitil_core/lib/eitil_core/safe_executions/safe_call.rb