• 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
    • [4.1 Beta 3] Mass-management tools: Call to a member function unpack() on null (Preview changes)

    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: [4.1 Beta 3] Mass-management tools: Call to a member function unpack() on null (Preview changes)

    • Issue Tools
      • View Changes
    1. issueid=5890 October 11, 2019 11:48 PM
      ACL ACL is offline
      Regular Member
      [4.1 Beta 3] Mass-management tools: Call to a member function unpack() on null (Preview changes)

      In VaultWiki 4.1 Beta 3 b003, attempting to preview the changes in the mass-management tools is interrupted by the following exception:
      An exception occurred: [Error] Call to a member function unpack() on null in src/addons/vw/vw/_core/view/cp/massive/vw.php on line 139
      Code:
      #0 src/addons/vw/vw/_core/view/reply/view/vw.php(48): vw_CP_Massive_View->preview(Array)
      #1 src/addons/vw/vw/_core/view/reply/base/vw.php(134): vw_Reply_View_View->render_type('json')
      #2 src/addons/vw/vw/XF/Mvc/View.php(87): vw_Reply_base_View->render('json')
      #3 src/XF/Mvc/Renderer/AbstractRenderer.php(91): vw\vw\XF\Mvc\View->renderJson()
      #4 src/XF/Mvc/Renderer/Json.php(63): XF\Mvc\Renderer\AbstractRenderer->renderViewObject('vw\\vw:Wiki', 'admin:vw_genera...', Array)
      #5 src/XF/Mvc/Dispatcher.php(418): XF\Mvc\Renderer\Json->renderView('vw\\vw:Wiki', 'admin:vw_genera...', Array)
      #6 src/XF/Mvc/Dispatcher.php(400): XF\Mvc\Dispatcher->renderView(Object(XF\Mvc\Renderer\Json), Object(XF\Mvc\Reply\View))
      #7 src/XF/Mvc/Dispatcher.php(360): XF\Mvc\Dispatcher->renderReply(Object(XF\Mvc\Renderer\Json), Object(XF\Mvc\Reply\View))
      #8 src/XF/Mvc/Dispatcher.php(53): XF\Mvc\Dispatcher->render(Object(XF\Mvc\Reply\View), 'json')
      #9 src/XF/App.php(2178): XF\Mvc\Dispatcher->run()
      #10 src/XF.php(390): XF\App->run()
      #11 admin.php(13): XF::runApp('XF\\Admin\\App')
      #12 {main}
      My site is almost ready to make the move to XenForo 2.1 (With VW Beta 3 - I can't wait any longer). One of the last wiki-specific tasks is to migrate the [table] bbcode to [wtable] before the upgrade and update any affected wiki pages. Without this change, tables stop working after the XF2.1 upgrade - the [table] bbcode tag is stripped when viewing or editing a page in XF2.1 (but is displayed in view source).
    Issue Details
    Issue Number 5890
    Issue Type Bug
    Project VaultWiki 4.x Series
    Category Admin Panel
    Status Fixed
    Priority 3 - Loss of Functionality
    Affected Version 4.1.0 Beta 3
    Fixed Version 4.1.0 Beta 4
    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. October 12, 2019 9:26 AM
      pegasus pegasus is offline
      VaultWiki Team
      Fixed in the next release. This occurs if the item you are attempting to preview will show no changes from the replace action.

      In src/addons/vw/vw/_core/view/cp/massive/vw.php, find:
      Code:
      list($segment, $class, $type, $tclass) = $diff_parser->unpack($entry, $i);
      Replace with:
      Code:
      					if (isset($diff_parser))
      					{
      						list($segment, $class, $type, $tclass) = $diff_parser->unpack($entry, $i);
      					}
      					else
      					{
      						$segment = $entry['segment1'];
      						$class = $entry['class1'];
      						$type = $entry['type1'];
      						$tclass = $entry['tclass1'];
      					}
      Reply Reply  
    2. October 12, 2019 9:56 AM
      ACL ACL is offline
      Regular Member
      Thank you. With the above code edit applied, I no longer run into the reported exception when trying to preview the changes.

      The 'no changes' preview might be due legacy MediaWiki syntax that I must have missed on some old wiki pages. For example, I have a wiki page from 2011 which is one of the first results in "Reviewing Prepared Results" for the search term [table]. That wiki page does contain a couple of tables however all of them use {| |} MediaWiki table syntax instead of [table][/table] - the page's last revision was before moving to VaultWiki. I do intend to go through these pages with the goal to disable the legacy MediaWiki support at the time of upgrading to XF2.1
      Reply Reply  
    3. October 12, 2019 10:07 AM
      ACL ACL is offline
      Regular Member
      Actually, scratch that theory . Some file/attachment pages are also included in the results where the placeholder text is used (the page has no text content of its own).
      Reply Reply  
    4. October 12, 2019 10:08 AM
      pegasus pegasus is offline
      VaultWiki Team
      Prepared Results don't necessarily contain the search-term portion of a search-replace action. The results only show a list of content that matches the "criteria" heading from the prior form, which is only selected areas and a few other things. It only tries to apply the replacement against each page after clicking Preview or when processing the final batch.

      Probably most of the Prepared Results that you ever try to preview will be 'no changes' because of this.
      Reply Reply  
    5. October 12, 2019 10:18 AM
      ACL ACL is offline
      Regular Member
      Oh, right. Understood - thank you for the explanation.

      I did notice one other minor issue with the result previews - the title is rendering as "Previewing changes to {1}"
      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 1:10 PM.
    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.