Remove Update button when unloaded

Fix duplicate list issue
This commit is contained in:
amcmanu3 2022-08-05 20:24:42 -04:00
parent 0642c61314
commit 8897856aef
2 changed files with 4 additions and 1 deletions

View File

@ -175,7 +175,8 @@ class ServersController(metaclass=Singleton):
f"{server['server_name']} at path {server['path']}. "
f"Skipping this server"
)
self.failed_servers.append(server)
if server not in self.failed_servers:
self.failed_servers.append(server)
continue
temp_server_dict = {

View File

@ -242,9 +242,11 @@
}}</a><br />
<small>{{ translate('serverConfig', 'stopBeforeDeleting', data['lang']) }}</small>
{% else %}
{% if not data['failed'] %}
<button onclick="send_command(serverId, 'update_executable');" id="update_executable"
style="max-width: 7rem;" class="btn btn-warning m-1 flex-grow-1">{{ translate('serverConfig',
'update', data['lang']) }}</button>
{% end %}
{% if not data['failed'] %}
<button onclick="deleteConfirm()" class="btn btn-sm btn-danger">{{ translate('serverConfig',
'deleteServer', data['lang']) }}</button>