mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-10 00:23:30 +01:00
Improve codeblock lang
This commit is contained in:
@@ -47,9 +47,9 @@ class RESTMethods {
|
||||
if (typeof content !== 'undefined') content = this.client.resolver.resolveString(content);
|
||||
|
||||
if (content) {
|
||||
if (typeof code === 'string') {
|
||||
if (typeof code !== 'undefined' && (typeof code !== 'boolean' || code === true)) {
|
||||
content = escapeMarkdown(this.client.resolver.resolveString(content), true);
|
||||
content = `\`\`\`${typeof code !== 'undefined' && code !== null ? code : ''}\n${content}\n\`\`\``;
|
||||
content = `\`\`\`${typeof code !== 'boolean' ? code || '' : ''}\n${content}\n\`\`\``;
|
||||
}
|
||||
|
||||
if (disableEveryone || (typeof disableEveryone === 'undefined' && this.client.options.disableEveryone)) {
|
||||
@@ -59,7 +59,7 @@ class RESTMethods {
|
||||
if (split) content = splitMessage(content, typeof split === 'object' ? split : {});
|
||||
}
|
||||
|
||||
const send = (chan) => {
|
||||
const send = chan => {
|
||||
if (content instanceof Array) {
|
||||
const messages = [];
|
||||
(function sendChunk(list, index) {
|
||||
|
||||
Reference in New Issue
Block a user