diff options
Diffstat (limited to 'core/store.rb')
-rw-r--r-- | core/store.rb | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/core/store.rb b/core/store.rb index ba49733..5e1cf67 100644 --- a/core/store.rb +++ b/core/store.rb @@ -14,6 +14,14 @@ module Dinobot @data ||= Hash.new end + def [](key) + @data[key] + end + + def []=(key, value) + @data[key] = value + end + def read @store.transaction(true) do @data = @store[:data] |