Fix crash when used without Treasurer

master
Wuzzy 2016-11-12 22:35:49 +01:00
parent 12aaec86b4
commit 1e72b43601
1 changed files with 3 additions and 1 deletions

View File

@ -105,7 +105,7 @@ local function rci()
end
if(treasures ~= nil) then
if(#treasures==1) then
if(#treasures>=1) then
return treasures[1]:get_name()
else
return ""
@ -131,6 +131,8 @@ local function rci()
else
return "default:diamond "..nextrandom(1,3)
end
else
return ""
end
end
end