Sha256: 77b2f36e90f3ae9eea2d0cc23e2e28b5c7dbe263a264f9a083346a0f37afee33

Contents?: true

Size: 330 Bytes

Versions: 1

Compression:

Stored size: 330 Bytes

Contents

module Concerns
  module Translatable
    class Config
      attr_reader :fields

      def initialize
        @fields = []
      end

      def add(field)
        @fields << field.to_sym unless @fields.include?(field.to_sym)
      end

      def allowed?(field)
        @fields.include?(field.to_sym)
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
udongo-0.1.0 app/models/concerns/translatable/config.rb