fix offline servers processing

This commit is contained in:
ghost 2024-01-09 00:31:24 +02:00
parent 04eeac5844
commit 741f6a3227
3 changed files with 12 additions and 2 deletions

View File

@ -224,6 +224,11 @@ class CrontabController extends AbstractController
continue; continue;
} }
catch (\Throwable $error)
{
continue;
}
finally finally
{ {
$server->Disconnect(); $server->Disconnect();

View File

@ -163,6 +163,11 @@ class MainController extends AbstractController
continue; continue;
} }
catch (\Throwable $error)
{
$status = false;
}
finally finally
{ {
$server->Disconnect(); $server->Disconnect();

View File

@ -48,13 +48,13 @@
{% block main_content %} {% block main_content %}
{% for server in servers %} {% for server in servers %}
<div class="border-default padding-8-px margin-y-8-px"> <div class="border-default padding-8-px margin-y-8-px">
{% if server.info.HostName %} {% if server.info.HostName is defined %}
<h2>{{ server.info.HostName }} [#{{ server.crc32server }}]</h2> <h2>{{ server.info.HostName }} [#{{ server.crc32server }}]</h2>
{% else %} {% else %}
<h2>#{{ server.crc32server }}</h2> <h2>#{{ server.crc32server }}</h2>
{% endif %} {% endif %}
<hr /> <hr />
{% if server.description.title %} {% if server.description.title is defined %}
<div class="margin-y-8-px"> <div class="margin-y-8-px">
{{ server.description.title }} {{ server.description.title }}
</div> </div>