Sha256: 12f080bf432098aacc7bece8d5bca10c8f631c22c0b02be8cb8081ffc4cac7d6
Contents?: true
Size: 700 Bytes
Versions: 12
Compression:
Stored size: 700 Bytes
Contents
module Dry module Validation module Messages class Namespaced < Messages::Abstract attr_reader :namespace, :messages, :root def initialize(namespace, messages) super() @namespace = namespace @messages = messages @root = messages.root end def key?(key, *args) messages.key?(key, *args) end def get(key, options = {}) messages.get(key, options) end def lookup_paths(tokens) super(tokens.merge(root: "#{root}.rules.#{namespace}")) + super end def default_locale messages.default_locale end end end end end
Version data entries
12 entries across 12 versions & 1 rubygems