summaryrefslogtreecommitdiff
path: root/controllers
diff options
context:
space:
mode:
Diffstat (limited to 'controllers')
-rw-r--r--controllers/instance.rb2
-rw-r--r--controllers/interfaces/cli.rb4
-rw-r--r--controllers/session.rb7
3 files changed, 4 insertions, 9 deletions
diff --git a/controllers/instance.rb b/controllers/instance.rb
index b22a785..503b388 100644
--- a/controllers/instance.rb
+++ b/controllers/instance.rb
@@ -23,7 +23,7 @@ module NanoBot
end
def cartridge
- puts YAML.dump(@safe_cartridge)
+ @safe_cartridge
end
def state
diff --git a/controllers/interfaces/cli.rb b/controllers/interfaces/cli.rb
index 2a93044..da027f7 100644
--- a/controllers/interfaces/cli.rb
+++ b/controllers/interfaces/cli.rb
@@ -54,9 +54,9 @@ module NanoBot
when 'repl'
bot.repl
when 'state'
- bot.state
+ pp bot.state
when 'cartridge'
- bot.cartridge
+ puts YAML.dump(bot.cartridge)
else
raise "TODO: [#{params[:command]}]"
end
diff --git a/controllers/session.rb b/controllers/session.rb
index afaca18..1eb600d 100644
--- a/controllers/session.rb
+++ b/controllers/session.rb
@@ -32,12 +32,7 @@ module NanoBot
end
def state
- pp({
- state: {
- path: @state_path,
- content: @state
- }
- })
+ { state: { path: @state_path, content: @state } }
end
def load_state