Sha256: 0390fa0b01f0504ca09aff2505eb54d34145a68e1456460988c2836ea582c732

Contents?: true

Size: 317 Bytes

Versions: 8

Compression:

Stored size: 317 Bytes

Contents

module Wasabi
  module CoreExt
    module Object

      # Returns +true+ if the Object is nil, false or empty. Implementation from ActiveSupport.
      def blank?
        respond_to?(:empty?) ? empty? : !self
      end unless method_defined?(:blank?)

    end
  end
end

Object.send :include, Wasabi::CoreExt::Object

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
wasabi-2.5.0 lib/wasabi/core_ext/object.rb
wasabi-2.4.1 lib/wasabi/core_ext/object.rb
wasabi-2.4.0 lib/wasabi/core_ext/object.rb
wasabi-2.3.0 lib/wasabi/core_ext/object.rb
wasabi-2.2.0 lib/wasabi/core_ext/object.rb
wasabi-2.1.1 lib/wasabi/core_ext/object.rb
wasabi-2.1.0 lib/wasabi/core_ext/object.rb
wasabi-2.0.0 lib/wasabi/core_ext/object.rb