diff --git a/lib/active_resource/railtie.rb b/lib/active_resource/railtie.rb index 0a0492de58..dc4e08d6af 100644 --- a/lib/active_resource/railtie.rb +++ b/lib/active_resource/railtie.rb @@ -23,7 +23,9 @@ class Railtie < Rails::Railtie end initializer "active_resource.deprecator" do |app| - app.deprecators[:active_resource] = ActiveResource.deprecator + if app.respond_to?(:deprecators) + app.deprecators[:active_resource] = ActiveResource.deprecator + end end end end