Fixed Moderator log copy/move posts link is relative, as pather is not applied as expected


Well-known member
Affected version
2.1.10 Patch 2
3) To support this we're now explicitly handling the base pathing of any moderator log action param that ends in url (generally we store URLs with nopath)
I'm fairly sure you want to check the key name (ie url), not the actual action param value (ie the url itself).

protected function getActionPhraseParams(ModeratorLog $log)
   $pather = \XF::app()['request.pather'];

   $params = $log->action_params;

   foreach ($params AS $key => $param)
      if (preg_match('/url$/i', $param))
         $params[$key] = $pather($param, 'base');

   return $params;
IMO, This should be preg_match('/url$/i', $key).

Otherwise these action_params are not transformed as expected;
{"url":"threads\/thread-title2.43027\/","title":"Thread title2"}

XF Bug Bot

XenForo bug fixer bot
Staff member
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.1.11).

Change log:
Properly apply pather to moderator log action phrase params
There may be a delay before changes are rolled out to the XenForo Community.