Use symbols for module configuration keys
This commit is contained in:
parent
f003d5505d
commit
09d8506f82
2 changed files with 2 additions and 2 deletions
|
@ -8,7 +8,7 @@ module Lain
|
|||
Modules = {
|
||||
'Credits' => {},
|
||||
'DDate' => {},
|
||||
'Fortune' => { 'command' => '/usr/bin/fortune -a' },
|
||||
'Fortune' => { :command => '/usr/bin/fortune -a' },
|
||||
'Help' => {},
|
||||
'Topic' => {},
|
||||
}
|
||||
|
|
|
@ -8,7 +8,7 @@ module Lain
|
|||
def on_message(muc, message)
|
||||
return unless /\A!fortune\b/ =~ message.body
|
||||
|
||||
muc.say("\nBEGIN FORTUNE COOKIE\n" + IO.popen(@config['command']).read.chomp + "\nEND FORTUNE COOKIE")
|
||||
muc.say("\nBEGIN FORTUNE COOKIE\n" + IO.popen(@config[:command]).read.chomp + "\nEND FORTUNE COOKIE")
|
||||
end
|
||||
|
||||
def commands
|
||||
|
|
Reference in a new issue