mirror of
https://github.com/discordjs/discord.js.git
synced 2026-05-31 16:10:08 +00:00
fix(StageInstanceManager#create): correctly resolve guildScheduledEvent (#11540)
This commit is contained in:
@@ -69,7 +69,7 @@ class StageInstanceManager extends CachedManager {
|
||||
if (typeof options !== 'object') throw new DiscordjsTypeError(ErrorCodes.InvalidType, 'options', 'object', true);
|
||||
const { guildScheduledEvent, topic, privacyLevel, sendStartNotification } = options;
|
||||
|
||||
const guildScheduledEventId = guildScheduledEvent && this.resolveId(guildScheduledEvent);
|
||||
const guildScheduledEventId = guildScheduledEvent && this.guild.scheduledEvents.resolveId(guildScheduledEvent);
|
||||
|
||||
const data = await this.client.rest.post(Routes.stageInstances(), {
|
||||
body: {
|
||||
|
||||
@@ -2,8 +2,9 @@
|
||||
|
||||
const process = require('node:process');
|
||||
const { GatewayIntentBits } = require('discord-api-types/v10');
|
||||
const { codeBlock } = require('@discordjs/formatters');
|
||||
const { token, prefix, owner } = require('./auth.js');
|
||||
const { Client, Events, Options, RESTEvents, codeBlock } = require('../src/index.js');
|
||||
const { Client, Events, Options, RESTEvents } = require('../src/index.js');
|
||||
|
||||
// eslint-disable-next-line no-console
|
||||
const log = (...args) => console.log(process.uptime().toFixed(3), ...args);
|
||||
@@ -44,7 +45,7 @@ const commands = {
|
||||
console.error(err.stack);
|
||||
res = err.message;
|
||||
}
|
||||
message.channel.send(codeBlock(res));
|
||||
message.channel.send(codeBlock(String(res).slice(0, 1992)));
|
||||
},
|
||||
ping: message => message.channel.send('pong'),
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user