Mercurial > prosody-modules
comparison mod_statistics/mod_statistics.lua @ 3414:66bda434d476
mod_statistics: Update 'top' to (hopefully) work with Prosody 0.11/Lua 5.2
author | Matthew Wild <mwild1@gmail.com> |
---|---|
date | Sun, 23 Dec 2018 11:00:38 +0000 |
parents | d7c014f91189 |
children |
comparison
equal
deleted
inserted
replaced
3413:6421c9f05e02 | 3414:66bda434d476 |
---|---|
129 function module.command( args ) | 129 function module.command( args ) |
130 local command = args[1]; | 130 local command = args[1]; |
131 if command == "top" then | 131 if command == "top" then |
132 local dir = module:get_directory(); | 132 local dir = module:get_directory(); |
133 package.path = dir.."/?.lua;"..dir.."/?.lib.lua;"..package.path; | 133 package.path = dir.."/?.lua;"..dir.."/?.lib.lua;"..package.path; |
134 local prosodytop = require "prosodytop"; | 134 local prosodytop = module:require "prosodytop"; |
135 prosodytop.run(); | 135 prosodytop.run(); |
136 end | 136 end |
137 end | 137 end |
138 | 138 |
139 if prosody and prosody.arg then | 139 if prosody and prosody.arg then |