Module: Streetlib::Vault
- Includes:
- Mu
- Defined in:
- lib/streetlib/vault.rb,
lib/streetlib/vault/error.rb,
lib/streetlib/vault/loader.rb,
lib/streetlib/vault/content.rb,
lib/streetlib/vault/version.rb
Defined Under Namespace
Classes: Content, Error, Loader
Constant Summary collapse
- VERSION =
"1.1.1"
Class Method Summary collapse
Class Method Details
.load(path:) ⇒ Object
11 12 13 14 15 16 17 |
# File 'lib/streetlib/vault.rb', line 11 def self.load(path:) result = Loader.load(path: path) if result.error? raise Error.new("Can't load file: #{path}. [code:#{result.code}]") end result.data.content end |