[FEATURE] Massively increased loading time

This commit is contained in:
Dunemask 2024-01-15 13:07:13 -07:00
parent b989f6efbe
commit 1a79ea7960
13 changed files with 145 additions and 55 deletions

View file

@ -28,6 +28,7 @@ export async function createServerEntry(serverSpec) {
version,
server_type,
memory,
backup_enabled: !!backup_interval, // We already verified the payload, so any backup key will work
backup_host,
backup_bucket_path,
backup_id,
@ -44,9 +45,29 @@ export async function createServerEntry(serverSpec) {
version,
server_type: serverType,
memory,
backup_enabled: backupEnabled,
backup_host: backupHost,
backup_bucket_path: backupPath,
backup_id: backupId,
backup_key: backupKey,
backup_interval: backupInterval,
} = entries[0];
const mclName = getMclName(host, id);
return { name, mclName, id, host, version, serverType, memory };
return {
name,
mclName,
id,
host,
version,
serverType,
memory,
backupEnabled,
backupHost,
backupPath,
backupId,
backupKey,
backupInterval,
};
} catch (e) {
asExpressClientError(e);
}
@ -73,6 +94,7 @@ export async function getServerEntry(serverId) {
version,
server_type: serverType,
memory,
backup_enabled: backupEnabled,
backup_host: backupHost,
backup_bucket_path: backupPath,
backup_id: backupId,
@ -88,12 +110,12 @@ export async function getServerEntry(serverId) {
version,
serverType,
memory,
backupEnabled,
backupHost,
backupPath,
backupId,
backupKey,
backupInterval
backupInterval,
};
} catch (e) {
asExpressClientError(e);