mirror of
https://github.com/AsgardEternal/SquadJS.git
synced 2024-09-28 14:04:25 -05:00
refactor: improper usage of hierarchy in squad-server/rcon.js getListPlayers()
This commit is contained in:
parent
5cd0286869
commit
2195006765
@ -131,7 +131,7 @@ export default class SquadRcon extends Rcon {
|
||||
};
|
||||
}
|
||||
|
||||
async getListPlayers(server) {
|
||||
async getListPlayers() {
|
||||
const response = await this.execute('ListPlayers');
|
||||
|
||||
const players = [];
|
||||
@ -144,7 +144,7 @@ export default class SquadRcon extends Rcon {
|
||||
);
|
||||
if (!match) continue;
|
||||
|
||||
if (server?.rcon?.addIds) server.rcon.addIds(match[3], match[2]);
|
||||
if (this.addIds) this.addIds(match[3], match[2]);
|
||||
|
||||
const data = match.groups;
|
||||
data.isLeader = data.isLeader === 'True';
|
||||
|
Loading…
Reference in New Issue
Block a user