Module: ActsAsKaltura::Config::ClassMethods

Defined in:
lib/acts_as_kaltura/config.rb

Instance Method Summary collapse

Instance Method Details

#kaltura_configs(env = Rails.env.to_s) ⇒ Object

Read kaltura YAML file and retrieve configuration for the given environment. Returns a hash of kaltura configuration.

kaltura_config('production')


40
41
42
43
44
45
46
47
48
# File 'lib/acts_as_kaltura/config.rb', line 40

def kaltura_configs(env = Rails.env.to_s)
  if self._kaltura_configs.nil?
    self._kaltura_configs =
        YAML.load(File.read(self._kaltura_config_file)).
            with_indifferent_access
  end

  self._kaltura_configs[env]
end

#overrode_kaltura_client?Boolean

Returns:

  • (Boolean)


31
32
33
# File 'lib/acts_as_kaltura/config.rb', line 31

def overrode_kaltura_client?
  _kaltura_options.include?(:setting_scope)
end