Compare commits
1 Commits
86c7eaf04c
...
4edbf32ef9
Author | SHA1 | Date |
---|---|---|
mio | 4edbf32ef9 |
|
@ -10,7 +10,7 @@
|
|||
|
||||
## Installation
|
||||
|
||||
- Install Lua and other dependencies. Examples:
|
||||
- Install Lua and other dependencies. Example:
|
||||
|
||||
- Debian/Ubuntu-based distributions: `apt-get install lua-socket lua-sec`
|
||||
|
||||
|
@ -53,8 +53,8 @@
|
|||
from IRC commands sent to the server like `JOIN` or `PART`. Name the
|
||||
handler after the code word that will be used to trigger the function and
|
||||
add it to `itte_handlers` so it can be automatically picked up by the
|
||||
module. For example, if the code users will type is "!hello" (where the "!"
|
||||
is a prefix to mark it as a bot code), name the function
|
||||
module. For example, if the code users will type is `!hello` (where `!` is
|
||||
a prefix to mark it as a bot code), name the function
|
||||
`itte_handlers.hello()`. Handler names cannot start with numbers or special
|
||||
characters.
|
||||
|
||||
|
|
6
itte.lua
6
itte.lua
|
@ -129,7 +129,11 @@ function itte.get_config(reload)
|
|||
-- Second-level nested tables
|
||||
if type(v) == "table" then
|
||||
for kk, vv in pairs(v) do
|
||||
itte.config[k][kk] = vv
|
||||
if (type(vv) == "table") or (type(vv) == "function") then
|
||||
itte.config[k] = v
|
||||
else
|
||||
itte.config[k][kk] = vv
|
||||
end
|
||||
end
|
||||
else
|
||||
itte.config[k] = v
|
||||
|
|
Loading…
Reference in New Issue