Sha256: 492b035b00289ec4d6304d8c9df2e84b9d23a6ddf089b020dd84862e7319bc5e

Contents?: true

Size: 374 Bytes

Versions: 1

Compression:

Stored size: 374 Bytes

Contents

# encoding: utf-8

require 'loaf/errors'

module Loaf
  module OptionsValidator
    def valid?(options)
      valid_options = Loaf::Configuration::VALID_ATTRIBUTES
      options.each_key do |key|
        if !valid_options.include?(key)
          raise Loaf::InvalidOptions.new(key, valid_options)
        end
      end
      true
    end
  end # OptionsValidator
end # Loaf

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
loaf-0.3.0 lib/loaf/options_validator.rb