forked from nalc/random_messages
avoid error on closing null file handle
This commit is contained in:
parent
365ffd23ad
commit
17d2fd9f75
1
init.lua
1
init.lua
@ -64,6 +64,7 @@ function random_messages.read_messages()
|
|||||||
-- blame the admin if not found
|
-- blame the admin if not found
|
||||||
output:write(S("Blame the server admin! He/She has probably not edited the random messages yet.\n"))
|
output:write(S("Blame the server admin! He/She has probably not edited the random messages yet.\n"))
|
||||||
output:write(S("Tell your dumb admin that this line is in (worldpath)/random_messages\n"))
|
output:write(S("Tell your dumb admin that this line is in (worldpath)/random_messages\n"))
|
||||||
|
return
|
||||||
else
|
else
|
||||||
-- or write default_input content in worldpath message file
|
-- or write default_input content in worldpath message file
|
||||||
local content = default_input:read("*all")
|
local content = default_input:read("*all")
|
||||||
|
Loading…
Reference in New Issue
Block a user