Fixed 'Click to expand...' not being removed

Jon W

Well-known member
Although this doesn't really affect anything (since there is sufficient CSS in place to hide the affected text), I noticed that there is some completely redundant code in the xenforo.js file:
Rich (BB code):
            $(document).on('click', '.bbCodeQuote .quoteContainer .quoteExpand', function(e) {
                $(this).remove('quoteCut');
                $(this).closest('.quoteContainer').toggleClass('expanded');
            });
should be:
Rich (BB code):
            $(document).on('click', '.bbCodeQuote .quoteContainer .quoteExpand', function(e) {
                $(this).closest('.quoteContainer').toggleClass('expanded');
                $(this).remove('.quoteCut');
            });
or simply:
Rich (BB code):
            $(document).on('click', '.bbCodeQuote .quoteContainer .quoteExpand', function(e) {
                $(this).remove('quoteCut');
                $(this).closest('.quoteContainer').toggleClass('expanded');
            });

At the moment the second line of code does absolutely nothing.

Edit: just noticed that the remove line needs to come after the toggleClass line.
 
Last edited:
Back
Top Bottom