module Reading::BlankAttribute
BlankAttribute
is for the errors and warnings below, which indicate that a attribute is blank in data for a new Item.
Attributes
attributes[R]
Public Class Methods
new(line_or_attribute = nil, label: nil)
click to toggle source
Calls superclass method
# File lib/reading/errors.rb, line 97 def initialize(line_or_attribute = nil, label: nil) line, label = from(line_or_attribute, label) super(line, label: label) end
Private Instance Methods
from(line_or_attribute, label)
click to toggle source
# File lib/reading/errors.rb, line 104 def from(line_or_attribute, label) if line_or_attribute.is_a?(Array) label = "Missing #{line_or_attribute.join(", ")}:" else line = line_or_attribute end [line, label] end