Disabled BBC affects Admins

Started by GL700Wing, May 18, 2017, 07:20:01 AM

Previous topic - Next topic

GL700Wing

I recently encountered an issue on an SMF 2.0.14 forum in which, when trying to view the details of a package installation error/manual edits required, the 'Operations' window was missing the 'codeheader' blocks (eg, Code: (Find) [Select], Code: (Replace) [Select]) - see attached.

I discovered the issue occurred because I had disabled the 'code' tag for posts and topics in Bulletin Board Code settings and I believe this is a bug because I don't think disabled BB codes should apply to Admins.

The fix I've implemented (which prevents disabled BB codes applying to Admins) is as follows:

In ./Sources/Subs.php
Find:
if (!empty($modSettings['disabledBBC']))

Replace with:
if (!empty($modSettings['disabledBBC']) && !allowedTo('admin_forum'))
Life doesn't have to be perfect to be wonderful ...

Slava
Ukraini!
"Before you allow people access to your forum, especially in an administrative position, you must be aware that that person can seriously damage your forum. Therefore, you should only allow people that you trust, implicitly, to have such access." -Douglas

live627


Advertisement: