mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-09 16:13:31 +01:00
Add shard client prop fetching, remove guild count fetching, improve eval
This commit is contained in:
@@ -150,6 +150,11 @@ class Client extends EventEmitter {
|
||||
} catch (err) {
|
||||
process.send({ _evalError: err });
|
||||
}
|
||||
} else if (message._fetchProp) {
|
||||
const props = message._fetchProp.split('.');
|
||||
let value = this; // eslint-disable-line consistent-this
|
||||
for (const prop of props) value = value[prop];
|
||||
process.send({ _fetchProp: message._fetchProp, _fetchPropValue: value });
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user