Sha256: af47db2a816f4e452b9ed098533757c24bdcc2289825f76c5c655806e497f562

Contents?: true

Size: 300 Bytes

Versions: 35

Compression:

Stored size: 300 Bytes

Contents

class Object

  ##
  # TODO: Improve this code, which works, but probably there's a better way
  #       to make the verification.
  #
  # Probably there's a better way to verify if a model responds to an STI
  # pattern.
  def self.is_sti?
    superclass.superclass == ActiveRecord::Base
  end

end

Version data entries

35 entries across 35 versions & 1 rubygems

Version Path
typus-3.0.11.rc4 lib/support/object.rb
typus-3.1.0.rc9 lib/support/object.rb
typus-3.0.11.rc3 lib/support/object.rb
typus-3.1.0.rc8 lib/support/object.rb
typus-3.1.0.rc7 lib/support/object.rb
typus-3.1.0.rc6 lib/support/object.rb
typus-3.1.0.rc5 lib/support/object.rb
typus-3.1.0.rc4 lib/support/object.rb
typus-3.1.0.rc3 lib/support/object.rb
typus-3.1.0.rc2 lib/support/object.rb
typus-3.0.11.rc2 lib/support/object.rb
typus-3.0.11.rc1 lib/support/object.rb
typus-3.1.0.rc1 lib/support/object.rb
typus-3.0.10 lib/support/object.rb
typus-3.0.9 lib/support/object.rb