lib/viator.rb in viator-0.1.1.1 vs lib/viator.rb in viator-0.1.1.2.freeze

- old
+ new

@@ -4,15 +4,14 @@ class Viator attr_writer :value attr_reader :errors attr_accessor :hide_value - class Errors < Array - end + Errors = Class.new(Array) def initialize(options = {}) @errors = Errors.new - @value = nil + @value = options[:value] @hide_value = (options[:hide_value] != false) end def success? @errors.length.zero?