Skip to content

Commit

Permalink
Merge branch 'master' of https://github.com/Sceleratis/Adonis
Browse files Browse the repository at this point in the history
  • Loading branch information
Sceleratis committed Feb 24, 2021
2 parents 9f48d08 + b612a4f commit 70f740a
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions WebPanel.lua
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
return function(Vargs)
local server = Vargs.Server;
local service = Vargs.Service;

local init = true
local HTTP = service.HttpService
local Encode = server.Functions.Base64Encode
Expand Down Expand Up @@ -224,15 +224,18 @@ return function(Vargs)

if init then
server.Logs:AddLog("Script", "WebPanel Initialization Complete")
server.Variables.WebPanel_Initiated = true
init = false
end
else
local code, msg = res.StatusCode, res.StatusMessage
if code ~= 520 or code ~= 524 then

if code ~= 520 and code ~= 524 then
server.Logs:AddLog("Script", "WebPanel Polling Error: "..msg.." ("..code..")")
server.Logs:AddLog("Errors", "WebPanel Polling Error: "..msg.." ("..code..")")
break
elseif code == 520 then
wait(5) --After the server restarts we want to make sure that it has time to inititate everything
end
end
wait()
Expand Down

0 comments on commit 70f740a

Please sign in to comment.