aboutsummaryrefslogtreecommitdiff
path: root/module/config.rb
diff options
context:
space:
mode:
authorDavid Vazgenovich Shakaryan <dvshakaryan@gmail.com>2014-04-21 14:48:09 -0700
committerDavid Vazgenovich Shakaryan <dvshakaryan@gmail.com>2014-04-21 14:48:09 -0700
commit7f94ea0c30bee85c0eecbd4ccb4c8e7efb3889bb (patch)
treec3520d0727314bff2dbfac006743672f825f605d /module/config.rb
parent211018e2f94c60fdf7a47b87cbcb07432f0fa25d (diff)
downloaddinobot-7f94ea0c30bee85c0eecbd4ccb4c8e7efb3889bb.tar.gz
dinobot-7f94ea0c30bee85c0eecbd4ccb4c8e7efb3889bb.tar.xz
Add simple getter/setter methods to Store.
Diffstat (limited to 'module/config.rb')
-rw-r--r--module/config.rb10
1 files changed, 5 insertions, 5 deletions
diff --git a/module/config.rb b/module/config.rb
index cf71bd4..0082260 100644
--- a/module/config.rb
+++ b/module/config.rb
@@ -17,9 +17,9 @@ module Dinobot
case args
when 'trigger'
- m.respond [:say, m.channel, @config.data[:trigger][:global]]
+ m.respond [:say, m.channel, @config[:trigger][:global]]
when 'debug'
- m.respond [:say, m.channel, @config.data[:debug].to_s]
+ m.respond [:say, m.channel, @config[:debug].to_s]
end
end
@@ -31,15 +31,15 @@ module Dinobot
case key
when 'trigger'
- @config.data[:trigger][:global] = val
+ @config[:trigger][:global] = val
@config.save
when 'debug'
case val
when 'true'
- @config.data[:debug] = true
+ @config[:debug] = true
@config.save
when 'false'
- @config.data[:debug] = false
+ @config[:debug] = false
@config.save
end
end