checkrights only shows the message when needed now (#21091)

This commit is contained in:
Contrabang
2023-05-22 22:27:36 +02:00
committed by GitHub
parent 34a7003c5a
commit 8f51e9d09e
+4 -3
View File
@@ -462,9 +462,10 @@
text = replacetext(text, "\[/i\]", "</I>")
text = replacetext(text, "\[u\]", "<U>")
text = replacetext(text, "\[/u\]", "</U>")
if(check_rights(R_EVENT))
text = replacetext(text, "\[signfont\]", "<font face=\"[signfont]\"><i>")
text = replacetext(text, "\[/signfont\]", "</i></font>")
if(findtext(text, "\[signfont\]") || findtext(text, "\[/signfont\]")) // Make sure the text is there before giving off an error
if(check_rights(R_EVENT))
text = replacetext(text, "\[signfont\]", "<font face=\"[signfont]\"><i>")
text = replacetext(text, "\[/signfont\]", "</i></font>")
if(sign)
text = replacetext(text, "\[sign\]", "<font face=\"[signfont]\"><i>[user ? user.real_name : "Anonymous"]</i></font>")
if(fields)