News:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu

SMF 2.0.7 Incorrect moderation log entries

Started by sides, April 23, 2014, 06:47:23 PM

Previous topic - Next topic

sides

Post.php line 2046

   // Log an act of moderation - modifying.
   if (!empty($moderationAction))
      logAction('modify', array('topic' => $topic, 'message' => (int) $_REQUEST['msg'], 'member' => $row['id_member'], 'board' => $board));

   if (isset($_POST['lock']) && $_POST['lock'] != 2)
      logAction('lock', array('topic' => $topicOptions['id'], 'board' => $topicOptions['board']));

   if (isset($_POST['sticky']) && !empty($modSettings['enableStickyTopics']))
      logAction('sticky', array('topic' => $topicOptions['id'], 'board' => $topicOptions['board']));


If you are unstickying or unlocking a topic from editing a post, it still always reports it in the mod log as being stickied/locked because it only checks if the $_POST is set, not its value. (logAction('unsticky'/'unlock'/etc) is missing.)

Advertisement: