From adab829d8fc24e0bc21737f5e125e19620b1f87c Mon Sep 17 00:00:00 2001 From: Alexander Harkness Date: Wed, 1 Oct 2014 20:14:28 +0100 Subject: Fixed broken code. --- MCServer/Plugins/APIDump/Hooks/OnServerPing.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/MCServer/Plugins/APIDump/Hooks/OnServerPing.lua b/MCServer/Plugins/APIDump/Hooks/OnServerPing.lua index 6d2325fe6..db1707e47 100644 --- a/MCServer/Plugins/APIDump/Hooks/OnServerPing.lua +++ b/MCServer/Plugins/APIDump/Hooks/OnServerPing.lua @@ -34,9 +34,9 @@ function OnServerPing(ClientHandle, ServerDescription, OnlinePlayers, MaxPlayers MaxPlayers = 0 -- Change favicon - if (cFile:IsFile("my-favicon.png")) then + if cFile:IsFile("my-favicon.png") then local FaviconData = cFile:ReadWholeFile("my-favicon.png") - if (FaviconData != "") then + if FaviconData ~= "" and FaviconData ~= nil then Favicon = Base64Encode(FaviconData) end end -- cgit v1.2.3