mirror of
https://github.com/mt-mods/mail.git
synced 2025-05-06 11:21:46 -04:00
Fix luacheck
This commit is contained in:
parent
49b1f0d400
commit
779ba48a2c
1 changed files with 7 additions and 7 deletions
|
@ -24,13 +24,6 @@ minetest.register_on_player_receive_fields(function(player, formname, fields)
|
|||
|
||||
-- then sort them
|
||||
|
||||
if not fields.sortfield or fields.sortfield == "" then
|
||||
sortfield = "3"
|
||||
end
|
||||
if not fields.sortdirection or fields.sortdirection == "" then
|
||||
sortdirection = "1"
|
||||
end
|
||||
|
||||
if not sortfield then
|
||||
local sortfield = fields.sortfield
|
||||
end
|
||||
|
@ -38,6 +31,13 @@ minetest.register_on_player_receive_fields(function(player, formname, fields)
|
|||
local sortdirection = fields.sortdirection
|
||||
end
|
||||
|
||||
if not fields.sortfield or fields.sortfield == "" then
|
||||
sortfield = "3"
|
||||
end
|
||||
if not fields.sortdirection or fields.sortdirection == "" then
|
||||
sortdirection = "1"
|
||||
end
|
||||
|
||||
local messagesInbox = mail.sort_messages(messagesInboxFiltered, sortfield, sortdirection, filter)
|
||||
local messagesSent = mail.sort_messages(messagesOutboxFiltered, sortfield, sortdirection, filter)
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue