method

read_json_attribute

Importance_0
v7.1.3.2 - Show latest stable - 0 notes - Class: TrixAttachment
read_json_attribute(name) private

No documentation

This method has no description. You can help the Ruby on Rails community by adding new notes.

Hide source
# File actiontext/lib/action_text/trix_attachment.rb, line 80
      def read_json_attribute(name)
        if value = node[name]
          begin
            JSON.parse(value)
          rescue => e
            Rails.logger.error "[#{self.class.name}] Couldn't parse JSON #{value} from NODE #{node.inspect}"
            Rails.logger.error "[#{self.class.name}] Failed with #{e.class}: #{e.backtrace}"
            nil
          end
        end
      end
Register or log in to add new notes.