• REGISTRATION REQUIREMENTS:

    Your username here MUST MATCH your XenForo username (connected to your XF license).

    Once you have registered here, then you need to start a conversation at xenforo.com w/Bob and provide the following:
    1. Your XenForo License Validation Token
    2. The Domain Name associated with the License
    NOTE: Your account will be validated once ALL requirements are verified/met. Thank you for your patience.

Fixed Macro public:xa_ams_comment_macros:user_info_simple is unknown

thomas1

New Member
AMS Premium
CAS Premium
EMS Early Adopter
IMS Premium
LD Premium
RMS Premium
SC Premium
UBS Premium
AMS Version
2.3.4
XenForo Version
2.3.4
PHP Version
8.3.12
Database & Version
10.6.19 (10.6.19-MariaDB-log)
Are there any errors being throw?
Yes
I just wanted to post this error we received today upon posting to the associated discussion thread:


Code:
ErrorException: Template error: [E_USER_WARNING] Macro public:xa_ams_comment_macros:user_info_simple is unknown src/XF/Template/Templater.php:749
    
    
#0 [internal function]: XF\Template\Templater->handleTemplateError(512, '[E_USER_WARNING...', '/home/*******/d...', 749)
#1 src/XF/Template/Templater.php(749): trigger_error('Macro public:xa...', 512)
#2 src/XF/Template/Templater.php(868): XF\Template\Templater->getTemplateMacro('public', 'xa_ams_comment_...', 'user_info_simpl...')
#3 src/addons/MaZ/AMP/XF/Template/Templater.php(159): XF\Template\Templater->callMacro('xa_ams_comment_...', 'user_info_simpl...', Array, Array, NULL)
#4 internal_data/code_cache/templates/l1/s41/public/xa_ams_comment_macros.php(608): MaZ\AMP\XF\Template\TemplaterAbstract->callMacro(NULL, 'user_info_simpl...', Array, Array)
#5 src/XF/Template/Templater.php(922): XF\Template\Templater->{closure}(Object(SV\StandardLib\XF\Template\Templater), Array, NULL)
#6 src/addons/MaZ/AMP/XF/Template/Templater.php(159): XF\Template\Templater->callMacro('xa_ams_comment_...', 'comment_deleted', Array, Array, Object(XF\Template\MacroState))
#7 internal_data/code_cache/templates/l1/s41/public/xa_ams_comment_macros.php(103): MaZ\AMP\XF\Template\TemplaterAbstract->callMacro(NULL, 'comment_deleted', Array, Array)
#8 src/XF/Template/Templater.php(922): XF\Template\Templater->{closure}(Object(SV\StandardLib\XF\Template\Templater), Array, NULL)
#9 src/addons/MaZ/AMP/XF/Template/Templater.php(159): XF\Template\Templater->callMacro('xa_ams_comment_...', 'comment_list', Array, Array, Object(XF\Template\MacroState))
#10 internal_data/code_cache/templates/l1/s41/public/xa_ams_article_view.php(1169): MaZ\AMP\XF\Template\TemplaterAbstract->callMacro(NULL, 'xa_ams_comment_...', Array, Array)
#11 src/XF/Template/Templater.php(1800): XF\Template\Templater->{closure}(Object(SV\StandardLib\XF\Template\Templater), Array, Object(XF\Template\ExtensionSet))
#12 src/addons/MaZ/AMP/Traits/Templater/XF22.php(52): XF\Template\Templater->renderTemplate('xa_ams_article_...', Array, true, NULL)
#13 src/XF/Template/Template.php(24): MaZ\AMP\XF\Template\Templater->renderTemplate('public:xa_ams_a...', Array)
#14 src/XF/Mvc/Renderer/Html.php(50): XF\Template\Template->render()
#15 src/XF/Mvc/Dispatcher.php(471): XF\Mvc\Renderer\Html->renderView('XenAddons\\AMS:A...', 'public:xa_ams_a...', Array)
#16 src/XF/Mvc/Dispatcher.php(453): XF\Mvc\Dispatcher->renderView(Object(XF\Mvc\Renderer\Html), Object(XF\Mvc\Reply\View))
#17 src/XF/Mvc/Dispatcher.php(412): XF\Mvc\Dispatcher->renderReply(Object(XF\Mvc\Renderer\Html), Object(XF\Mvc\Reply\View))
#18 src/XF/Mvc/Dispatcher.php(66): XF\Mvc\Dispatcher->render(Object(XF\Mvc\Reply\View), 'html')
#19 src/XF/App.php(2826): XF\Mvc\Dispatcher->run()
#20 src/XF.php(806): XF\App->run()
#21 index.php(23): XF::runApp('XF\\Pub\\App')
#22 {main}

array(4) {
  ["url"] => string(50) "/articles/sake-the-japanese-national-beverage.***/"
  ["referrer"] => string(22) "https://****.com/****/"
  ["_GET"] => array(0) {
  }
  ["_POST"] => array(0) {
  }
}
 
Weird. That's what I have in xa_ams_comment_macros (lines 110-115):

PHP:
        <div class="message-inner">
            <div class="message-cell message-cell--user">
                <xf:macro id="message_macros::user_info_simple" 
                    arg-user="{$comment.User}"
                    arg-fallbackName="{$comment.username}" />
            </div>
 
Weird. That's what I have in xa_ams_comment_macros (lines 110-115):

PHP:
        <div class="message-inner">
            <div class="message-cell message-cell--user">
                <xf:macro id="message_macros::user_info_simple"
                    arg-user="{$comment.User}"
                    arg-fallbackName="{$comment.username}" />
            </div>
You are looking at the wrong macro.... The issue is with the macro comment_deleted

Look at line 367

It's currently

<xf:macro id="message_macros" name="user_info_simple"

When it should be

<xf:macro id="message_macros::user_info_simple"
 
Thanks, I really need new glasses! 😊
 
  • Haha
Reactions: Bob
Back
Top