This commit is contained in:
Skillet 2023-04-17 19:34:42 -04:00
parent 87ae29ccc6
commit 0ae235703d

View File

@ -1120,7 +1120,6 @@ export default class MapVote extends DiscordBasePlugin {
const rconLayers = (await this.server.rcon.execute('ListLayers'))?.split('\n') || []; const rconLayers = (await this.server.rcon.execute('ListLayers'))?.split('\n') || [];
rconLayers.shift(); rconLayers.shift();
if (rconLayers.length > 0) Layers.layers = Layers.layers.filter((l) => l != null && rconLayers.includes(l.layerid))
// this.verbose(1, 'RCON Layers', rconLayers.length, this.mapLayer(rconLayers[ 0 ])) // this.verbose(1, 'RCON Layers', rconLayers.length, this.mapLayer(rconLayers[ 0 ]))
for (const layer of rconLayers) { for (const layer of rconLayers) {
if (!Layers.layers.find((e) => e?.layerid === layer)) { if (!Layers.layers.find((e) => e?.layerid === layer)) {