Add logging
This commit is contained in:
parent
30ae194420
commit
8e68af8277
@ -82,6 +82,7 @@ module.exports = (robot) ->
|
|||||||
done = ['fatto', 'ecco qui', 'ecco']
|
done = ['fatto', 'ecco qui', 'ecco']
|
||||||
group_list (list) ->
|
group_list (list) ->
|
||||||
chat = res.match[4]
|
chat = res.match[4]
|
||||||
|
user = res.message.user.name
|
||||||
if not chat in list
|
if not chat in list
|
||||||
res.send res.random nope
|
res.send res.random nope
|
||||||
return
|
return
|
||||||
@ -89,5 +90,7 @@ module.exports = (robot) ->
|
|||||||
res.send res.random denied
|
res.send res.random denied
|
||||||
return
|
return
|
||||||
res.send res.random ok
|
res.send res.random ok
|
||||||
run_command "chat_add_user #{chat} #{res.message.user.name}"
|
run_command "chat_add_user #{chat} #{user}", (reply) ->
|
||||||
|
robot.logger.info "add user #{user} to chat #{chat}"
|
||||||
|
robot.logger.info 'result: ' + reply
|
||||||
res.send res.random done
|
res.send res.random done
|
||||||
|
Loading…
Reference in New Issue
Block a user