• 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
    • LogicException: Macro admin:option_macros :: option_row() error: vw_DM_Comment_Controller_XF2::getStructure() must be overridden src/XF/Mvc/Entity/Entity.php:2034

    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: LogicException: Macro admin:option_macros :: option_row() error: vw_DM_Comment_Controller_XF2::getStructure() must be overridden src/XF/Mvc/Entity/Entity.php:2034

    • Issue Tools
      • View Changes
    1. issueid=6281 December 4, 2021 8:08 AM
      wolven wolven is offline
      New Member
      LogicException: Macro admin:option_macros :: option_row() error: vw_DM_Comment_Controller_XF2::getStructure() must be overridden src/XF/Mvc/Entity/Entity.php:2034

      Hi folks
      I have following error encounted. It has been triggerd by another add-on but points to vw.

      Stack-Trace

      #0 src/XF/Mvc/Entity/Manager.php(72): XF\Mvc\Entity\Entity::getStructure(Object(XF\Mvc\Entity\S tructure))
      #1 src/addons/SV/SignupAbuseBlocking/Option/DefaultLinkAction.php(24): XF\Mvc\Entity\Manager->getEntityStructure('vw_DM_Comment_C...')
      #2 src/XF/Entity/Option.php(79): SV\SignupAbuseBlocking\Option\DefaultLinkAction::renderOp tion(Object(SV\ContentRatings\XF\Entity\Option), Array)
      #3 src/XF/Template/Templater.php(1191): XF\Entity\Option->renderDisplayCallback(Array)
      #4 internal_data/code_cache/templates/l2/s0/admin/option_macros.php(206): XF\Template\Templater->method(Object(SV\ContentRatings\XF\Entity\Option), 'renderDisplayCa...', Array)
      #5 src/XF/Template/Templater.php(824): XF\Template\Templater->{closure}(Object(vw\vw\XF\Template\Templater22), Array, NULL)
      #6 internal_data/code_cache/templates/l2/s0/admin/addon_options.php(60): XF\Template\Templater->callMacro('option_macros', 'option_row', Array, Array)
      #7 src/XF/Template/Templater.php(1651): XF\Template\Templater->{closure}(Object(vw\vw\XF\Template\Templater22), Array, NULL)
      #8 src/addons/vw/vw/XF/Template/Templater22.php(34): XF\Template\Templater->renderTemplate('addon_options', Array, true, NULL)
      #9 src/XF/Template/Template.php(24): vw\vw\XF\Template\Templater22->renderTemplate('admin:addon_opt...', Array)
      #10 src/XF/Mvc/Renderer/Html.php(50): XF\Template\Template->render()
      #11 src/XF/Mvc/Dispatcher.php(460): XF\Mvc\Renderer\Html->renderView('XF:AddOn\\Option...', 'admin:addon_opt...', Array)
      #12 src/XF/Mvc/Dispatcher.php(442): XF\Mvc\Dispatcher->renderView(Object(XF\Mvc\Renderer\Html), Object(XF\Mvc\Reply\View))
      #13 src/XF/Mvc/Dispatcher.php(402): XF\Mvc\Dispatcher->renderReply(Object(XF\Mvc\Renderer\Html), Object(XF\Mvc\Reply\View))
      #14 src/XF/Mvc/Dispatcher.php(60): XF\Mvc\Dispatcher->render(Object(XF\Mvc\Reply\View), 'html')
      #15 src/XF/App.php(2351): XF\Mvc\Dispatcher->run()
      #16 src/XF.php(517): XF\App->run()
      #17 admin.php(13): XF::runApp('XF\\Admin\\App')
      #18 {main}

      Status der Anfrage

      array(4) {
      ["url"] => string(56) "/stage1/admin.php?add-ons/SV-SignupAbuseBlocking/options"
      ["referrer"] => string(50) "https://xf2t.tt-board.eu/stage1/admin.php?add-ons/"
      ["_GET"] => array(1) {
      ["add-ons/SV-SignupAbuseBlocking/options"] => string(0) ""
      }
      ["_POST"] => array(0) {
      }
      }

      Any ideas?
      Cheers
    Issue Details
    Issue Number 6281
    Issue Type Bug
    Project VaultWiki 4.x Series
    Category Admin Panel
    Status Fixed
    Priority 4 - Warnings / Script Errors
    Affected Version 4.1.3
    Fixed Version 4.1.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. December 4, 2021 12:35 PM
      pegasus pegasus is offline
      VaultWiki Team
      We'll go ahead and provide a getStructure method, but if this add-on is going to try to use it to make changes to the structure and eventually make updates through the entity, they are going to be in for a rude awakening. Wiki entities don't let you do that, and that will not be changed. You have to go through the abstraction layer. It's an issue of data integrity. If the data is not prepared a certain way first, the entity would be corrupted.

      In src/addons/vw/vw/XF/Entity/EntityBase.php, find:
      Code:
      protected function vwPrepareStructure($controller, $structure)
      BEFORE it, add:
      Code:
      	public static function getStructure(Structure $structure)
      	{
      		$entity = new static(\XF::app()->em(), $structure);
      
      		return $structure;
      	}
      Again, add-ons that provide new functionality for content-types should be opt-in per content-type, and they should require the content-type to provide its own handler-class. That is how you ensure data integrity in XenForo. You can't just go updating random entities without having an understanding of how that entity behaves.
      Reply Reply  
    2. December 6, 2021 8:12 AM
      wolven wolven is offline
      New Member
      thanks for reply. I will go back to the developer of the add-on and give this feeback.
      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 8:22 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.