UPDATE! !Previous post not enough correct!
for correct processing of rights of moderation with this hack, we need to this piece of code:
PHP Code:
//visitormessage, groupmessage, picturecomment
if(count(array_intersect($fr_itemsToTrack, array('visitormessage', 'groupmessage', 'picturecomment')))>0) {
$query = "SELECT COUNT(type) AS total, type
FROM ". TABLE_PREFIX ."moderation
GROUP BY type";
$fr_result = $vbulletin->db->query_read($query);
while($fr_entry = $vbulletin->db->fetch_array($fr_result)) {
$fr_modItems[$fr_entry['type']] ['total'] = $fr_entry['total'];
}
}
rearrange upward, so that it would-be over
PHP Code:
//reply - post
if(in_array('reply', $fr_itemsToTrack)) {
$query = "SELECT COUNT(*) AS num
FROM " . TABLE_PREFIX . "moderation AS moderation
INNER JOIN " . TABLE_PREFIX . "post AS post ON (moderation.primaryid = post.postid)
INNER JOIN " . TABLE_PREFIX . "thread AS thread ON (post.threadid = thread.threadid)
WHERE type = 'reply' ". $m_forums;
$fr_result = $vbulletin->db->query_first($query);
$fr_modItems['reply'] ['total'] = $fr_result['num'];
}
================================================== =========================================
================================================== =========================================
Anf another suggest is for that would not appear a database error when entering/leaving forum by moderator/super-moderator/administrator without any forum moderated, string:
PHP Code:
if(!isSuperMod($vbulletin)){
must be replaced with:
PHP Code:
if(!isSuperMod($vbulletin) AND can_moderate()){
================================================== =========================================
Both issues from same module:
Showing notifications