Sha256: eb98f7592a87cac3797a427d159a1ba68def75bb2cfc6f28ddbf526bd42eb522

Contents?: true

Size: 419 Bytes

Versions: 73

Compression:

Stored size: 419 Bytes

Contents

module Kernel
  # Standard in rails. See official documentation[http://api.rubyonrails.org/classes/Object.html]
  def try(method_id, *args, &block)
    send(method_id, *args, &block) unless self.nil?
  end unless method_defined? :try

  # Standard in rails. See official documentation[http://api.rubyonrails.org/classes/Object.html]
  def returning(obj)
    yield obj
    obj
  end unless method_defined? :returning
end

Version data entries

73 entries across 73 versions & 3 rubygems

Version Path
marcandre-backports-1.8.0 lib/backports/rails/kernel.rb
marcandre-backports-1.8.1 lib/backports/rails/kernel.rb
marcandre-backports-1.8.2 lib/backports/rails/kernel.rb
marcandre-backports-1.8.3 lib/backports/rails/kernel.rb
marcandre-backports-1.8.4 lib/backports/rails/kernel.rb
marcandre-backports-1.9.0 lib/backports/rails/kernel.rb
backports-3.0.3 lib/backports/rails/kernel.rb
backports-3.0.2 lib/backports/rails/kernel.rb
backports-3.0.1 lib/backports/rails/kernel.rb
backports-3.0.0 lib/backports/rails/kernel.rb
backports-2.8.2 lib/backports/rails/kernel.rb
backports-2.8.1 lib/backports/rails/kernel.rb
backports-2.8.0 lib/backports/rails/kernel.rb
backports-2.7.1 lib/backports/rails/kernel.rb
backports-2.7.0 lib/backports/rails/kernel.rb
backports-2.6.7 lib/backports/rails/kernel.rb
backports-2.6.6 lib/backports/rails/kernel.rb
backports-2.6.5 lib/backports/rails/kernel.rb
fragrant-0.0.5 vendor/bundle/ruby/1.9.1/gems/backports-2.6.4/lib/backports/rails/kernel.rb
backports-2.6.4 lib/backports/rails/kernel.rb