Class: ActiveRecord::DynamicMatchers::FindAllBy

Inherits:
Method
  • Object
show all
Includes:
DeprecatedFinder, DeprecationWarning, Finder
Defined in:
lib/active_record/deprecated_finders/dynamic_matchers.rb

Class Method Summary collapse

Instance Method Summary collapse

Methods included from DeprecationWarning

#body, #deprecation_warning

Methods included from DeprecatedFinder

#body, #signature

Class Method Details

.prefixObject



67
68
69
# File 'lib/active_record/deprecated_finders/dynamic_matchers.rb', line 67

def self.prefix
  "find_all_by"
end

Instance Method Details

#deprecation_alternativeObject



79
80
81
# File 'lib/active_record/deprecated_finders/dynamic_matchers.rb', line 79

def deprecation_alternative
  "Post.where(...).all"
end

#finderObject



71
72
73
# File 'lib/active_record/deprecated_finders/dynamic_matchers.rb', line 71

def finder
  "where"
end

#resultObject



75
76
77
# File 'lib/active_record/deprecated_finders/dynamic_matchers.rb', line 75

def result
  "#{super}.to_a"
end