Sha256: 1daa4119616d93abfd3196cd71e25e660183c2bb295b133b5ec9c69c5fe6e656

Contents?: true

Size: 407 Bytes

Versions: 5

Compression:

Stored size: 407 Bytes

Contents

module Oxidized
  class Source
    class NoConfig < OxidizedError; end

    def initialize
      @map = (Oxidized.config.model_map or {})
    end

    def map_model model
      @map.has_key?(model) ? @map[model] : model
    end

    def node_var_interpolate var
      case var
      when "nil"   then nil
      when "false" then false
      when "true"  then true
      else var
      end
    end
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
oxidized-0.25.1 lib/oxidized/source/source.rb
oxidized-0.25.0 lib/oxidized/source/source.rb
oxidized-0.24.0 lib/oxidized/source/source.rb
oxidized-0.23.0 lib/oxidized/source/source.rb
oxidized-0.22.0 lib/oxidized/source/source.rb