Sha256: 851cec447f843cde5cd06222049c04b38f67ca811e21d3a91a41808b460732fb

Contents?: true

Size: 459 Bytes

Versions: 10

Compression:

Stored size: 459 Bytes

Contents

# frozen_string_literal: true

module Zizia
  class MetadataUsage
    include Singleton

    def usage
      YAML.load_file(config)
    end

    private

      def default_location
        File.join(File.dirname(__FILE__), '../../config/zizia/usage.yml')
      end

      def config
        return default_location unless File.exist?(Rails.root.join("config", "zizia", "usage.yml"))
        Rails.root.join("config", "zizia", "usage.yml")
      end
  end
end

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
zizia-6.0.1 app/lib/zizia/metadata_usage.rb
zizia-6.0.0 app/lib/zizia/metadata_usage.rb
zizia-5.5.0 app/lib/zizia/metadata_usage.rb
zizia-5.4.0 app/lib/zizia/metadata_usage.rb
zizia-5.3.0 app/lib/zizia/metadata_usage.rb
zizia-5.2.0 app/lib/zizia/metadata_usage.rb
zizia-5.1.0 app/lib/zizia/metadata_usage.rb
zizia-5.0.1 app/lib/zizia/metadata_usage.rb
zizia-5.0.0 app/lib/zizia/metadata_usage.rb
zizia-4.6.0.alpha.01 app/lib/zizia/metadata_usage.rb