Fixed Warning points and duration are still editable when unchecked


XenForo moderator
Staff member
I have Manage all warnings set to Not Set.

I have unchecked the Points and expiry time are editable when giving warning field for a pre-defined warning

However, when issuing a warning, it is still possible to change the points and expiry date.

It also doesn't work if the permission is set to Never.


XenForo developer
Staff member
This permission really just needs to be renamed to be clearer (as it only controls deleting of others' warnings).


XenForo moderator
Staff member
Now that you've explained it Mike, it works fine.

It was just a bit of erroneous information I was given as to what the permission was doing.
We won't mention any names though ;)

The unchecked Points and expiry time are editable when giving warning field is an issue though as they can be adjusted, and if doing so, the following error is returned:

Server Error

Undefined variable: expireInput
  1. XenForo_Application::handlePhpError() in XenForo/ControllerPublic/Member.php at line 631
  2. XenForo_ControllerPublic_Member->actionWarn() in XenForo/FrontController.php at line 310
  3. XenForo_FrontController->dispatch() in XenForo/FrontController.php at line 132
  4. XenForo_FrontController->run() in C:/xampplite/htdocs/xftest/index.php at line 13


that's coming from
            if ($warning && !$warning['is_editable'])
                $dwInput['points'] = $warning['points_default'];
                $dwInput['expiry_date'] = (
                    $expireInput['expiry_type'] == 'never' ? 0
                    : strtotime('+' . $warning['expiry_default'] . ' ' . $expireInput['expiry_type'])
in XenForo_ControllerPublic_Member

$expireInput should be IMO $warning