make sure validate always returns a useful number

e.g. /hotbar 999 --> return 16
master
Vanessa Dannenberg 2019-04-20 10:14:45 -04:00
parent 0e37dc7009
commit 5a7267afa7
1 changed files with 2 additions and 0 deletions

View File

@ -6,6 +6,8 @@ local function validate_size(s)
if (size == 8 or size == 16 or size == 23 or size == 24 or size == 32)
and size <= maxslots then
return size
else
return 16
end
end