aboutsummaryrefslogtreecommitdiffstats
path: root/activemodel/lib/active_model/naming.rb
diff options
context:
space:
mode:
authorGrant Hutchins <nertzy@gmail.com>2012-03-10 17:50:03 -0500
committerGrant Hutchins <nertzy@gmail.com>2012-03-10 18:02:36 -0500
commitbf8d7574bfb80b44ba353bf055122efbaa3d57da (patch)
tree237e30baeaed90474b80b22c0926a93dbf315435 /activemodel/lib/active_model/naming.rb
parentd5d241cb2c696f13e2c16efca0d24565a6e1c0a5 (diff)
downloadrails-bf8d7574bfb80b44ba353bf055122efbaa3d57da.tar.gz
rails-bf8d7574bfb80b44ba353bf055122efbaa3d57da.tar.bz2
rails-bf8d7574bfb80b44ba353bf055122efbaa3d57da.zip
Remove ActiveModel::Naming#partial_path
It was deprecated in 3.2
Diffstat (limited to 'activemodel/lib/active_model/naming.rb')
-rw-r--r--activemodel/lib/active_model/naming.rb5
1 files changed, 1 insertions, 4 deletions
diff --git a/activemodel/lib/active_model/naming.rb b/activemodel/lib/active_model/naming.rb
index fd0bc4e8e9..b22d9539b0 100644
--- a/activemodel/lib/active_model/naming.rb
+++ b/activemodel/lib/active_model/naming.rb
@@ -6,13 +6,11 @@ require 'active_support/core_ext/object/blank'
module ActiveModel
class Name < String
- attr_reader :singular, :plural, :element, :collection, :partial_path,
+ attr_reader :singular, :plural, :element, :collection,
:singular_route_key, :route_key, :param_key, :i18n_key
alias_method :cache_key, :collection
- deprecate :partial_path => "ActiveModel::Name#partial_path is deprecated. Call #to_partial_path on model instances directly instead."
-
def initialize(klass, namespace = nil, name = nil)
name ||= klass.name
@@ -27,7 +25,6 @@ module ActiveModel
@element = ActiveSupport::Inflector.underscore(ActiveSupport::Inflector.demodulize(self)).freeze
@human = ActiveSupport::Inflector.humanize(@element).freeze
@collection = ActiveSupport::Inflector.tableize(self).freeze
- @partial_path = "#{@collection}/#{@element}".freeze
@param_key = (namespace ? _singularize(@unnamespaced) : @singular).freeze
@i18n_key = self.underscore.to_sym