Class: Reputation::RailsVersion

Inherits:
Object
  • Object
show all
Defined in:
lib/reputation/rails_version.rb

Class Method Summary collapse

Class Method Details

.rails_2?Boolean

Returns:

  • (Boolean)


8
9
10
# File 'lib/reputation/rails_version.rb', line 8

def self.rails_2?
  defined?(Rails) && Rails::VERSION::MAJOR == 2
end

.rails_3?Boolean

Returns:

  • (Boolean)


4
5
6
# File 'lib/reputation/rails_version.rb', line 4

def self.rails_3?
  defined?(Rails) && Rails::VERSION::MAJOR == 3
end