Fixed Warning definition fields can have text that is too long for the warning or conversation


Well-known member
Affected version
2.2.4, 1.5.x
It's possible to create a warning definition with:

1. a title that is longer than the maximum length of a warning title
2. a conversation title that is longer than the maximum length of a conversation title

There won't be any error when the warning definition is created, nor will there be any error when warnings are issued. In the first scenario, the title will be truncated. In the second scenario, the conversation creation attempt will silently fail without notifying the moderator, which can result in significant confusion.

Similarly, when issuing a warning, it is probably possible to enter a conversation title that is too long, though I haven't tested this. Other fields might also cause issues, but I've only tested the warning title and conversation title; I suspect any field that's store in a phrase will have a similar problem.

It shouldn't be possible to create warning definitions that result in invalid warnings or conversations. Similarly, conversation creation shouldn't fail silently; the whole warning should fail if the conversation is invalid.

This has been an issue at least as far back as XenForo 1.5.x and at least as recently as XenForo 2.2.4.
Welcome, @FTL! When the XenForo team resolves a bug report, a message is posted in the thread indicating which version will receive the patch. If the bug is rejected for any reason, there will be a message explaining why.
Thank you for reporting this issue, it has now been resolved. We are aiming to include any changes that have been made in a future XF release (2.2.6).

Change log:
Fix bad maxlength setting for warning definition titles and impose a maxlength for warning definition conversation titles.
There may be a delay before changes are rolled out to the XenForo Community.
Top Bottom