Warning Improvements by Xon

Warning Improvements by Xon 2.12.2

No permission to download
Code:
TypeError: SV\WarningImprovements\XF\Repository\Warning::getReadableContentAction(): Return value must be of type ?XF\Phrase, string returned in src/addons/SV/WarningImprovements/XF/Repository/Warning.php at line 111
[LIST=1]
[*]SV\WarningImprovements\XF\Repository\Warning->getReadableContentAction() in src/addons/SV/WarningImprovements/XF/Repository/Warning.php at line 81
[*]SV\WarningImprovements\XF\Repository\Warning->SV\WarningImprovements\XF\Repository\{closure}() in src/XF.php at line 907
[*]XF::asVisitor() in src/addons/SV/WarningImprovements/Globals.php at line 35
[*]SV\WarningImprovements\Globals::asVisitorWithLang() in src/addons/SV/WarningImprovements/XF/Repository/Warning.php at line 40
[*]SV\WarningImprovements\XF\Repository\Warning->getSvWarningReplaceables() in src/addons/SV/WarningImprovements/XF/Service/User/Warn.php at line 246
[*]SV\WarningImprovements\XF\Service\User\Warn->SV\WarningImprovements\XF\Service\User\{closure}() in src/XF.php at line 907
[*]XF::asVisitor() in src/addons/SV/WarningImprovements/Globals.php at line 35
[*]SV\WarningImprovements\Globals::asVisitorWithLang() in src/addons/SV/WarningImprovements/XF/Service/User/Warn.php at line 218
[*]SV\WarningImprovements\XF\Service\User\Warn->doAsWarningIssuerForSv() in src/addons/SV/WarningImprovements/XF/Service/User/Warn.php at line 237
[*]SV\WarningImprovements\XF\Service\User\Warn->setupConversation() in src/XF/Service/User/WarnService.php at line 217
[*]XF\Service\User\WarnService->sendConversation() in src/addons/SV/WarningImprovements/XF/Service/User/Warn.php at line 273
[*]SV\WarningImprovements\XF\Service\User\Warn->SV\WarningImprovements\XF\Service\User\{closure}() in src/XF.php at line 907
[*]XF::asVisitor() in src/addons/SV/WarningImprovements/Globals.php at line 35
[*]SV\WarningImprovements\Globals::asVisitorWithLang() in src/addons/SV/WarningImprovements/XF/Service/User/Warn.php at line 218
[*]SV\WarningImprovements\XF\Service\User\Warn->doAsWarningIssuerForSv() in src/addons/SV/WarningImprovements/XF/Service/User/Warn.php at line 272
[*]SV\WarningImprovements\XF\Service\User\Warn->sendConversation() in src/XF/Service/User/WarnService.php at line 185
[*]XF\Service\User\WarnService->_save() in src/addons/SV/WarningImprovements/XF/Service/User/Warn.php at line 113
[*]SV\WarningImprovements\XF\Service\User\Warn->_save() in src/XF/Service/ValidateAndSavableTrait.php at line 42
[*]XF\Service\User\WarnService->save() in src/XF/ControllerPlugin/WarnPlugin.php at line 48
[*]XF\ControllerPlugin\WarnPlugin->actionWarn() in src/addons/SV/WarningImprovements/XF/ControllerPlugin/Warn.php at line 63
[*]SV\WarningImprovements\XF\ControllerPlugin\Warn->actionWarn() in src/XF/Pub/Controller/PostController.php at line 527
[*]XF\Pub\Controller\PostController->actionWarn() in src/XF/Mvc/Dispatcher.php at line 362
[*]XF\Mvc\Dispatcher->dispatchClass() in src/XF/Mvc/Dispatcher.php at line 264
[*]XF\Mvc\Dispatcher->dispatchFromMatch() in src/XF/Mvc/Dispatcher.php at line 121
[*]XF\Mvc\Dispatcher->dispatchLoop() in src/XF/Mvc/Dispatcher.php at line 63
[*]XF\Mvc\Dispatcher->run() in src/XF/App.php at line 2826
[*]XF\App->run() in src/XF.php at line 806
[*]XF::runApp() in index.php at line 23
[/LIST]
 
@Xon

Thanks for the update. With XF 2.3.3, it appears the Warning Category field is missing from the warning_edit ACP page. Looks like the sv_warningimprovements_warning_edit5 template modification find criteria needs to be updated.
 
@Xon

Thanks for the update. With XF 2.3.3, it appears the Warning Category field is missing from the warning_edit ACP page. Looks like the sv_warningimprovements_warning_edit5 template modification find criteria needs to be updated.

It appears this is an issue with several template modifications, also seeing the issue with warning_action_edit.
 
Hello, thanks for this beautiful develop.
How can i hide this option for all my moderators? I just need that all is set mandatory to radio view and not other chose:

1736693918110.webp

I do not remeber this options before... maybe i edited it a few year ago, do not remember, is there an Admin Control Panel setting for remove this choice? or i have to edit the template?
Thanks.
 
Xon, can you change your addons (Warning and Report improvements) so I don't get an error when I extend thread titles? Reference: https://xenforo.com/community/threa...racter-thread-title-limit.215208/post-1732987

Error:
Code:
RuntimeException: Warning:93, Warning log-content_title: Please enter a value using 255 characters or fewer. in src/addons/SV/ReportImprovements/Service/WarningLog/Creator.php at line 515
SV\ReportImprovements\Service\WarningLog\Creator->_validate() in src/XF/Service/ValidateAndSavableTrait.php at line 19
SV\ReportImprovements\Service\WarningLog\Creator->validate() in src/addons/SV/ReportImprovements/Repository/ReportQueue.php at line 245
SV\ReportImprovements\Repository\ReportQueue->SV\ReportImprovements\Repository\{closure}() in src/XF.php at line 625
XF::asVisitor() in src/addons/SV/ReportImprovements/Repository/ReportQueue.php at line 240
SV\ReportImprovements\Repository\ReportQueue->logToReport() in src/addons/SV/ReportImprovements/Behavior/ReportResolver.php at line 173
SV\ReportImprovements\Behavior\ReportResolver->logToReport() in src/addons/SV/ReportImprovements/Behavior/ReportResolver.php at line 61
SV\ReportImprovements\Behavior\ReportResolver->postSave() in src/XF/Mvc/Entity/Entity.php at line 1285
XF\Mvc\Entity\Entity->save() in src/XF/Service/User/Warn.php at line 174
XF\Service\User\Warn->_save() in src/addons/SV/WarningImprovements/XF/Service/User/Warn.php at line 113
SV\WarningImprovements\XF\Service\User\Warn->_save() in src/addons/SV/ReportImprovements/XF/Service/User/Warn.php at line 103
SV\ReportImprovements\XF\Service\User\Warn->_save() in src/XF/Service/ValidateAndSavableTrait.php at line 42
XF\Service\User\Warn->save() in src/XF/ControllerPlugin/Warn.php at line 43
XF\ControllerPlugin\Warn->actionWarn() in src/addons/SV/WarningImprovements/XF/ControllerPlugin/Warn.php at line 63
SV\WarningImprovements\XF\ControllerPlugin\Warn->actionWarn() in src/addons/SV/ReportImprovements/XF/ControllerPlugin/Warn.php at line 133
SV\ReportImprovements\XF\ControllerPlugin\Warn->actionWarn() in src/XF/Pub/Controller/Post.php at line 491
XF\Pub\Controller\Post->actionWarn() in src/XF/Mvc/Dispatcher.php at line 352
XF\Mvc\Dispatcher->dispatchClass() in src/XF/Mvc/Dispatcher.php at line 258
XF\Mvc\Dispatcher->dispatchFromMatch() in src/XF/Mvc/Dispatcher.php at line 115
XF\Mvc\Dispatcher->dispatchLoop() in src/XF/Mvc/Dispatcher.php at line 57
XF\Mvc\Dispatcher->run() in src/XF/App.php at line 2513
XF\App->run() in src/XF.php at line 524
XF::runApp() in index.php at line 20
 
You'll need to patch the column xf_sv_warning_log.title and then in php; SV\ReportImprovements\Entity\WarningLog, you'll need to update this line:
PHP:
'title'                 => ['type' => self::STR, 'maxLength' => 255, 'default' => '', 'noIndex' => true]
 
then in php; SV\ReportImprovements\Entity\WarningLog, you'll need to update this line:
I'll have to do that every time I update your addon? Couldn't you just set it to something high like 500 so it removes the limit for anyone who wants to do this?
 
I'll have to do that every time I update your addon? Couldn't you just set it to something high like 500 so it removes the limit for anyone who wants to do this?

I'ld recommend a small add-on to just patch the column definitions without needing to touch any addons or XF files directly
 
Back
Top Bottom