• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

Fixed Error when creating album (Cannot call method canEditTags on a non-object (NULL))

Affected version
2.0

Steve F

Well-known member
#1
Get this error each time I upload media when creating an album.
ErrorException: Template error: Cannot call method canEditTags on a non-object (NULL)
src/XF/Template/Templater.php:833
Code:
#0 [internal function]: XF\Template\Templater->handleTemplateError(512, 'Cannot call met...', '/home/*******/p...', 833, Array)
#1 /home/*******/public_html/src/XF/Template/Templater.php(833): trigger_error('Cannot call met...', 512)
#2 /home/*******/public_html/internal_data/code_cache/templates/l1/s136/public/xfmg_media_add_on_insert.php(19): XF\Template\Templater->method(NULL, 'canEditTags', Array)
#3 /home/*******/public_html/src/XF/Template/Templater.php(1133): XF\Template\Templater->{closure}(Object(SV\ContentRatings\XF\Template\Templater), Array)
#4 /home/*******/public_html/src/XF/Template/Template.php(24): XF\Template\Templater->renderTemplate('xfmg_media_add_...', Array)
#5 /home/*******/public_html/src/XF/Mvc/Renderer/Json.php(81): XF\Template\Template->render()
#6 /home/*******/public_html/src/XF/Mvc/Renderer/Json.php(65): XF\Mvc\Renderer\Json->renderHtmlFallback('XFMG:Media\\Add\\...', 'public:xfmg_med...', Array)
#7 /home/*******/public_html/src/XF/Mvc/Dispatcher.php(315): XF\Mvc\Renderer\Json->renderView('XFMG:Media\\Add\\...', 'public:xfmg_med...', Array)
#8 /home/*******/public_html/src/XF/Mvc/Dispatcher.php(286): XF\Mvc\Dispatcher->renderView(Object(XF\Mvc\Renderer\Json), Object(XF\Mvc\Reply\View))
#9 /home/*******/public_html/src/XF/Mvc/Dispatcher.php(44): XF\Mvc\Dispatcher->render(Object(XF\Mvc\Reply\View), 'json')
#10 /home/*******/public_html/src/XF/App.php(1777): XF\Mvc\Dispatcher->run()
#11 /home/*******/public_html/src/XF.php(320): XF\App->run()
#12 /home/*******/public_html/index.php(13): XF::runApp('XF\\Pub\\App')
#13 {main}
Code:
array(4) {
  ["url"] => string(20) "/media/add/on-insert"
  ["referrer"] => string(41) "https://********.com/media/albums/create"
  ["_GET"] => array(0) {
  }
  ["_POST"] => array(5) {
    ["name_prefix"] => string(8) "media[3]"
    ["_xfRequestUri"] => string(20) "/media/albums/create"
    ["_xfWithData"] => string(1) "1"
    ["_xfToken"] => string(8) "********"
    ["_xfResponseType"] => string(4) "json"
  }
}