summaryrefslogtreecommitdiff
path: root/api.lua
diff options
context:
space:
mode:
authorAndrew Ward <anjayward@gmail.com>2013-11-07 08:58:40 +0000
committerAndrew Ward <anjayward@gmail.com>2013-11-07 08:58:40 +0000
commitee438e31f8d714ce3b83fabfc5ce400b6e03a35a (patch)
treec09450941231c252a4efcc285f85f571d1fdd417 /api.lua
parent9f61f2e600281286fda4a059250ece78e4f79807 (diff)
Fix /list_awards
Diffstat (limited to 'api.lua')
-rw-r--r--api.lua5
1 files changed, 3 insertions, 2 deletions
diff --git a/api.lua b/api.lua
index 23de354..ecbc48c 100644
--- a/api.lua
+++ b/api.lua
@@ -185,8 +185,9 @@ minetest.register_chatcommand("list_awards", {
params = "",
description = "list_awards: list your awards",
func = function(name, param)
- if not awards.players[name] then
- minetest.chat_send_player(name, "Unable to find your award listings!")
+ if not awards.players[name] or not awards.players[name].unlocked then
+ minetest.chat_send_player(name, "You do not have any awards")
+ return
end
minetest.chat_send_player(name, name.."'s awards:")