mirror of
https://github.com/ZeppelinBot/Zeppelin.git
synced 2025-05-21 08:45:03 +00:00
leftover conflicts
This commit is contained in:
parent
4187886cff
commit
cd46abb578
2 changed files with 0 additions and 37 deletions
|
@ -39,17 +39,9 @@ export const NicknameCmd = utilityCmd({
|
|||
const oldNickname = args.member.nickname || "<none>";
|
||||
|
||||
try {
|
||||
<<<<<<< HEAD
|
||||
await args.member.setNickname(args.nickname ?? null);
|
||||
} catch {
|
||||
msg.channel.send(errorMessage("Failed to change nickname"));
|
||||
=======
|
||||
await args.member.edit({
|
||||
nick: args.nickname,
|
||||
});
|
||||
} catch {
|
||||
msg.channel.createMessage(errorMessage("Failed to change nickname"));
|
||||
>>>>>>> 1ad3f4dd (removed unused exception parameter)
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
@ -786,35 +786,6 @@ export function deactivateMentions(content: string): string {
|
|||
return content.replace(/@/g, "@\u200b");
|
||||
}
|
||||
|
||||
<<<<<<< HEAD
|
||||
=======
|
||||
/**
|
||||
* Disable inline code in the given string by replacing backticks/grave accents with acute accents
|
||||
* FIXME: Find a better way that keeps the grave accents? Can't use the code block approach here since it's just 1 character.
|
||||
*/
|
||||
export function disableInlineCode(content: string): string {
|
||||
return content.replace(/`/g, "\u00b4");
|
||||
}
|
||||
|
||||
/**
|
||||
* Disable code blocks in the given string by adding invisible unicode characters between backticks
|
||||
*/
|
||||
export function disableCodeBlocks(content: string): string {
|
||||
return content.replace(/`/g, "`\u200b");
|
||||
}
|
||||
|
||||
/**
|
||||
* Disable bold in the given string by escaping the asterisks
|
||||
*/
|
||||
export function disableBold(content: string): string {
|
||||
let i = 0;
|
||||
return content.replace(/\*\*(\*)?/g, (_, match) => {
|
||||
if (match) return ++i % 2 ? `${match}\\*\\*` : `\\*\\*${match}`;
|
||||
return "\\*\\*";
|
||||
});
|
||||
}
|
||||
|
||||
>>>>>>> 67f0227a (the commmand now sends the nickname of the member when a nickname isnt provided)
|
||||
export function useMediaUrls(content: string): string {
|
||||
return content.replace(/cdn\.discord(app)?\.com/g, "media.discordapp.net");
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue