diff --git a/lib/active_model/serializer.rb b/lib/active_model/serializer.rb index f96eb8a6..a1175dbc 100644 --- a/lib/active_model/serializer.rb +++ b/lib/active_model/serializer.rb @@ -20,7 +20,7 @@ module ActiveModel def embed(type, options={}) CONFIG.embed = type CONFIG.include = true if options[:include] - warn <<-WARN + ActiveSupport::Deprecation.warn <<-WARN ** Notice: embed is deprecated. ** The use of .embed method on a Serializer will be soon removed, as this should have a global scope and not a class scope. Please use the global .setup method instead: