On 09/27/2012 10:40 AM, mtaylor wrote:

In app/models/image_management/provider_image.rb:

>  
> -    accepts_nested_attributes_for :target_image
> +    # FIXME Check to see if this is a setting we can add to Rails configuration.
> +    # i.e. json_include_resource_name = true

Thanks. I'll remove those methods and update the config.


Reply to this email directly or view it on GitHub.

It seems that github does not send a mail when a comment is updated.  In case you are following comments in mail I've pasted my updated comment below:

Thanks. I'll remove those methods and update the config.

Comment 2

After a little more consideration, I'm not sure we want to set this in the config. The setting is on ActiveRecord::Base and therefore would override any settings in the host application. I am going to leave this as it is for now and follow this up later with a patch. We could implement this using this setting but by either:

class ImageManagement::Base < ActiveRecord::Base
include_root_in_json = false
end

class ImageManagement::TargetImage < ImageManagement::Base
...

What are your thoughts?