• Register
    • Help

    striker  0 Items
    Currently Supporting
    • Home
    • News
    • Forum
    • Wiki
    • Support
      • Manage Subscriptions
      • FAQ
      • Support For
        • VaultWiki 4.x Series
        • VaultWiki.org Site
    • What's New?
    • Buy Now
    • Manual
    • 
    • Support
    • VaultWiki 4.x Series
    • Bug
    • ghost Wiki edits in XF approval queue

    1. Welcome to VaultWiki.org, home of the wiki add-on for vBulletin and XenForo!

      VaultWiki allows your existing forum users to collaborate on creating and managing a site's content pages. VaultWiki is a fully-featured and fully-supported wiki solution for vBulletin and XenForo.

      The VaultWiki Team encourages you to join our community of forum administrators and check out VaultWiki for yourself.

    Issue: ghost Wiki edits in XF approval queue

    • Issue Tools
      • View Changes
    1. issueid=6494 3 Weeks Ago 2:48 PM
      Alfa1 Alfa1 is offline
      Distinguished Member
      ghost Wiki edits in XF approval queue

      This seems a minor bug.
      Please check the approval queue of my site and go the the filters. Under content type it will list the content types that are in the queue. You will see 'wiki edit'. When you activate this filter there is no content there. This was not the case yesterday.
    Issue Details
    Issue Number 6494
    Issue Type Bug
    Project VaultWiki 4.x Series
    Category Editing Pages
    Status Fixed
    Priority 3 - Loss of Functionality
    Affected Version 4.1.8
    Fixed Version 4.1.9
    Milestone (none)
    Software DependencyXenForo 2.x
    License TypePaid
    Users able to reproduce bug 0
    Users unable to reproduce bug 0
    Attachments 0
    Assigned Users (none)
    Tags (none)




    1. 3 Weeks Ago 10:07 AM
      pegasus pegasus is offline
      VaultWiki Team
      From what I can tell, when XenForo generates the content-type filters, it adds a filter whenever there is at least 1 of that content-type waiting for approval, but doesn't restrict this to content the user is actually allowed to view/approve. So you are seeing a list of content-types that is not based on your permissions, but then when you filter the content it checks your permission for each one. In this way, you can end up with an empty approval queue that claims to contain a non-zero number of entries.

      Since you said it happened over the last few days, most likely you changed permissions recently, so now you can no longer see certain entries that you were able to see before. For example, in another thread you asked how to hide certain tabs on area pages (https://www.vaultwiki.org/threads/6338/) and I listed which permissions affect each tab. It is possible that you removed permission from yourself to moderate wiki content, since that is one of the permissions I discussed.
      Reply Reply  
    2. 3 Weeks Ago 2:52 PM
      Alfa1 Alfa1 is offline
      Distinguished Member
      Permissions analysis for my account shows that all staff permissions are set to yet.
      I changed the permissions in the registered group that had NEVER to NO. I've set all admin permissions to YES.
      But it still doesn't show up.
      Reply Reply  
    3. 3 Weeks Ago 12:32 PM
      pegasus pegasus is offline
      VaultWiki Team
      When I check the filters on your site, I also have a filter for Direct Message Reply, but when I filter with it, it shows no results either. My guess is the problem you're seeing is a more global issue, although I suppose it could be a coincidence and VaultWiki has the same bug as Direct Message Reply.

      However, I can see that the demo has a similar issue for Wiki File Updates in the approval queue. When I check the database, there are multiple entries for the type, but I cannot see them in the approval queue. When I check the IDs against the database, I confirmed that at least 1 of them is content that exists, so it is not orphaned content. You may be correct that the permissions are not resolving correctly, or there may be another issue. Hopefully any solution to my issue is relevant to yours.
      Reply Reply  
    4. 3 Weeks Ago 12:54 PM
      Alfa1 Alfa1 is offline
      Distinguished Member
      Direct message moderation is restricted by usergroup permission:
      View moderated Direct Messages / messages
      I enabled that usergroup for your account now.
      Reply Reply  
    5. 3 Weeks Ago 12:55 PM
      Alfa1 Alfa1 is offline
      Distinguished Member
      The usergroup has all permissions for wiki. But maybe I need to add it here again?
      /admin.php?wiki/moderator/&moderatorid=1&do=edit
      Reply Reply  
    6. 3 Weeks Ago 8:24 AM
      Alfa1 Alfa1 is offline
      Distinguished Member
      I see in the DB that there are 6 vwrevision in xf_job:
      14254
      14293
      14264
      14314
      14324

      Looking at these numbers, these seem quite old. There are revisions with number 28000+
      How can I make these visible for review?
      Reply Reply  
    7. 3 Weeks Ago 11:46 PM
      pegasus pegasus is offline
      VaultWiki Team
      I had a number of ghost edits on my site too. It looks like they were over 5 years old, and they were actually edits that were already approved but for some reason XenForo still thinks they are queued. I could not find a situation that would cause that. The only solution for that would be to remove the orphaned records from xf_approval_queue. Possibly there was a bug around 2020 that was fixed around that time, but I cannot find any code change related to it. Unless you can confirm the exact same behavior, my assumption is that these were generated during development testing and are irrelevant to any real usage.

      However, I was able to imagine a situation where an edit doesn't show in the queue but is still flagged as needing approval. The only potential cause I could find for that was automated edits. Sometimes this might occur during specific upgrades, but you can do it manually using mass edits. Basically if you have edits in the approval queue and those edits happen to match the mass edit replace criteria, a new edit is auto-generated with the changes. Unlike editing manually, when the page is locked for editing until the edit is reviewed, auto-generating an edit bypasses this. Now because the edit waiting for approval is a moot edit (there are newer edits), the system doesn't allow moderators to approve/deny.

      This is a bit annoying because the system will change in 4.2, where we can have multiple new edits that need to be merged. But we can't do this in the current version. Instead, we just have to show the entry in the queue and only allow moderators to Deny.

      In src/addons/vw/vw/_core/model/ui/tab/revision/vw.php, find and remove:
      Code:
      			if ($item['dateline'] < $extreme['current_dateline'])
      			{
      				return false;
      			}
      			else if ($item['dateline'] == $extreme['current_dateline'])
      			{
      				// test for rollback to pending
      				$page = vw_Hard_Core::controller('Fetch')->get('Page', $item['itemid']);
      
      				if (!$page OR !isset($page['has_pending']))
      				{
      					return false;
      				}
      			}
      In src/addons/vw/vw/Handler/ApprovalQueue/Revision.php, find:
      Code:
      class Revision extends base
      {
      AFTER it, add:
      Code:
      	public function getTemplateData(\XF\Entity\ApprovalQueue $unapprovedItem)
      	{
      		$params = parent::getTemplateData($unapprovedItem);
      
      		if (!\vw_Hard_Core::model('Version')->installed('4.2.0 Alpha 0'))
      		{
      			$item = $params['content']->toArray();
      			$itemid = $item['pageid'];
      			$extreme = \vw_Hard_Core::controller('Fetch/Page')->to_the_extreme($itemid);
      			$ok = true;
      
      			if ($item['dateline'] < $extreme['current_dateline'])
      			{
      				$ok = false;
      			}
      			else if ($item['dateline'] == $extreme['current_dateline'])
      			{
      				// test for rollback to pending
      				$page = \vw_Hard_Core::controller('Fetch')->get('Page', $item['itemid']);
      
      				if (!$page OR !isset($page['has_pending']))
      				{
      					$ok = false;
      				}
      			}
      
      			if (!$ok)
      			{
      				unset($params['vwActions']['approve']);
      			}
      		}
      
      		return $params;
      	}
      Marking this as Fixed in the next release, since we will now show moot edits in the approval queue with the only option being to Deny them, rather than hiding them.

      This has been more thoroughly fixed in the next release, by decoupling the permissions checks in can_approve_tab. We have individualized checks for can_approve_tab vs can_deny_tab. They normally mean the same thing, except for edits, where approval can only be performed against the newest edit in the current version. A new can_approval_tab is now used to determine whether to show approval queue entries or the Change Moderation Status tab. It emulates the behavior from previous versions by returning true if the user can at least 1 of can_approve_tab or can_deny_tab.
      Reply Reply  
    + Reply

    Assigned Users
    Loading Please Wait
    Tags
    Loading Please Wait
    • Contact Us
    • License Agreement
    • Privacy
    • Terms
    • Top
    All times are GMT -4. The time now is 5:17 AM.
    This site uses cookies to help personalize content, to tailor your experience, and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Learn more… Accept Remind me later
  • striker
    Powered by vBulletin® Version 4.2.5 Beta 2
    Copyright © 2025 vBulletin Solutions Inc. All rights reserved.
    Search Engine Optimisation provided by DragonByte SEO (Pro) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
    Copyright © 2008 - 2024 VaultWiki Team, Cracked Egg Studios, LLC.