diff options
author | Soopyboo32 <49228220+Soopyboo32@users.noreply.github.com> | 2022-08-27 14:13:01 +0800 |
---|---|---|
committer | Soopyboo32 <49228220+Soopyboo32@users.noreply.github.com> | 2022-08-27 14:13:01 +0800 |
commit | fad4a00aa51bf5cbb2de945c9cd8200c60c97c3a (patch) | |
tree | 5ec6190f552e8c5260f25b88aa467f6ca2a91bcb /utils | |
parent | e296d7d95b1c0f2971827f4bdb3b5c9873ed1456 (diff) | |
download | SoopyV2-fad4a00aa51bf5cbb2de945c9cd8200c60c97c3a.tar.gz SoopyV2-fad4a00aa51bf5cbb2de945c9cd8200c60c97c3a.tar.bz2 SoopyV2-fad4a00aa51bf5cbb2de945c9cd8200c60c97c3a.zip |
bugfixes with guild category
Diffstat (limited to 'utils')
-rw-r--r-- | utils/utils.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/utils/utils.js b/utils/utils.js index 0e916ae..1f6cd6e 100644 --- a/utils/utils.js +++ b/utils/utils.js @@ -130,7 +130,7 @@ let utils = { return c }, ["&" + color]).map(a => { if (a.match(/(?:(?:https?|ftp|file):\/\/|www\.|ftp\.)(?:\([-A-Z0-9+&@#\/%=~_|$?!:,.]*\)|[-A-Z0-9+&@#\/%=~_|$?!:,.])*(?:\([-A-Z0-9+&@#\/%=~_|$?!:,.]*\)|[A-Z0-9+&@#\/%=~_|$])/igm)) { - return new TextComponent("&" + color + "&n" + a + "&" + color + ' ').setHover("show_text", "Click to open " + a.trim()).setClick("open_url", a.trim()) + return new TextComponent("&" + color + "&n" + a + "&" + color + ' ').setHover("show_text", "Click to open " + a.trim().replace(/^(?:[&§][0-9a-fmn])+|(?:[&§][0-9a-fmn])+$/g, "")).setClick("open_url", a.trim()) } else { return new TextComponent(a + ' ') } |