summaryrefslogtreecommitdiff
path: root/controllers/instance.rb
diff options
context:
space:
mode:
authoricebaker <icebaker@proton.me>2023-05-11 20:21:13 -0300
committericebaker <icebaker@proton.me>2023-05-11 20:21:13 -0300
commitef689ada3a9807084310e5356536ee730450083d (patch)
tree83f49f0d60ffe96031d063af7ff1b919772a0c6b /controllers/instance.rb
parentec5e25547a401141586c87621266f9cd68c59e3c (diff)
improving storage
Diffstat (limited to 'controllers/instance.rb')
-rw-r--r--controllers/instance.rb6
1 files changed, 5 insertions, 1 deletions
diff --git a/controllers/instance.rb b/controllers/instance.rb
index 5635658..bee4dfb 100644
--- a/controllers/instance.rb
+++ b/controllers/instance.rb
@@ -4,6 +4,7 @@ require 'yaml'
require_relative '../logic/helpers/hash'
require_relative '../components/provider'
+require_relative '../components/storage'
require_relative './interfaces/repl'
require_relative './session'
@@ -34,7 +35,10 @@ module NanoBot
def load_cartridge!(path)
@cartridge = Logic::Helpers::Hash.symbolize_keys(
- YAML.safe_load(File.read(path), permitted_classes: [Symbol])
+ YAML.safe_load(
+ File.read(Components::Storage.cartridge_path(path)),
+ permitted_classes: [Symbol]
+ )
)
inject_environment_variables!(@cartridge)