Commit cb9dfaa8 authored by Robert May's avatar Robert May

Replace odd JSON usage with standard parser

parent 20d1bda1
...@@ -44,8 +44,8 @@ module ConfigurationHelper ...@@ -44,8 +44,8 @@ module ConfigurationHelper
import_export_config = config_hash(config) import_export_config = config_hash(config)
excluded_attributes = import_export_config[:excluded_attributes][relation_name.to_sym] excluded_attributes = import_export_config[:excluded_attributes][relation_name.to_sym]
included_attributes = import_export_config[:included_attributes][relation_name.to_sym] included_attributes = import_export_config[:included_attributes][relation_name.to_sym]
attributes = attributes - JSON[excluded_attributes.to_json] if excluded_attributes attributes = attributes - JSON.parse(excluded_attributes.to_json) if excluded_attributes
attributes = attributes & JSON[included_attributes.to_json] if included_attributes attributes = attributes & JSON.parse(included_attributes.to_json) if included_attributes
attributes attributes
end end
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment