djs-selfbot-v13 3.7.21 → 3.7.23
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -606,6 +606,15 @@ class Message extends Base {
|
|
|
606
606
|
* @readonly
|
|
607
607
|
*/
|
|
608
608
|
get editable() {
|
|
609
|
+
const permissions = this.channel?.permissionsFor(this.client.user);
|
|
610
|
+
if (!permissions) return false;
|
|
611
|
+
|
|
612
|
+
const hasPermission = this.channel?.isThread?.()
|
|
613
|
+
? permissions.has(Permissions.FLAGS.SEND_MESSAGES_IN_THREADS, false)
|
|
614
|
+
: permissions.has(Permissions.FLAGS.SEND_MESSAGES, false);
|
|
615
|
+
|
|
616
|
+
if (!hasPermission) return false;
|
|
617
|
+
|
|
609
618
|
const precheck = Boolean(
|
|
610
619
|
this.author.id === this.client.user.id &&
|
|
611
620
|
!deletedMessages.has(this) &&
|
|
@@ -618,7 +627,6 @@ class Message extends Base {
|
|
|
618
627
|
if (this.channel?.isThread()) {
|
|
619
628
|
if (this.channel.archived) return false;
|
|
620
629
|
if (this.channel.locked) {
|
|
621
|
-
const permissions = this.channel.permissionsFor(this.client.user);
|
|
622
630
|
if (!permissions?.has(Permissions.FLAGS.MANAGE_THREADS, true)) return false;
|
|
623
631
|
}
|
|
624
632
|
}
|
|
@@ -172,6 +172,16 @@ class MessagePayload {
|
|
|
172
172
|
allowedMentions = Util.cloneObject(allowedMentions);
|
|
173
173
|
allowedMentions.replied_user = allowedMentions.repliedUser;
|
|
174
174
|
delete allowedMentions.repliedUser;
|
|
175
|
+
|
|
176
|
+
const guild = this.target.guild ?? this.target.channel?.guild;
|
|
177
|
+
if (guild && !this.isWebhook) {
|
|
178
|
+
const permissions = this.target.channel?.permissionsFor(this.target.client.user);
|
|
179
|
+
if (permissions) {
|
|
180
|
+
if (allowedMentions.parse?.includes('everyone') && !permissions.has(Permissions.FLAGS.MENTION_EVERYONE, false)) {
|
|
181
|
+
allowedMentions.parse = allowedMentions.parse.filter(p => p !== 'everyone');
|
|
182
|
+
}
|
|
183
|
+
}
|
|
184
|
+
}
|
|
175
185
|
}
|
|
176
186
|
|
|
177
187
|
let message_reference;
|
package/src/util/Options.js
CHANGED
|
@@ -197,16 +197,16 @@ class Options extends null {
|
|
|
197
197
|
browser: 'Discord Client',
|
|
198
198
|
release_channel: 'stable',
|
|
199
199
|
client_version: '1.0.9215',
|
|
200
|
-
os_version: '10
|
|
200
|
+
os_version: '10',
|
|
201
201
|
os_arch: 'x64',
|
|
202
202
|
app_arch: 'x64',
|
|
203
203
|
system_locale: 'en-US',
|
|
204
204
|
has_client_mods: false,
|
|
205
205
|
client_launch_id: randomUUID(),
|
|
206
206
|
browser_user_agent: UserAgent,
|
|
207
|
-
browser_version: '
|
|
207
|
+
browser_version: '146.0.0.0',
|
|
208
208
|
os_sdk_version: '19045',
|
|
209
|
-
client_build_number:
|
|
209
|
+
client_build_number: 521835,
|
|
210
210
|
native_build_number: 72186,
|
|
211
211
|
client_event_source: null,
|
|
212
212
|
launch_signature: randomUUID(),
|