Fatal error: Uncaught Error: Call to a member function addMessage() on null in /var/www/html/httpdocs/magento2/lib/internal/Magento/Framework/Message/Manager.php:143 Stack trace: #0 /var/www/html/httpdocs/magento2/lib/internal/Magento/Framework/Message/Manager.php(174): Magento\Framework\Message\Manager->addMessage(Object(Magento\Framework\Message\Error), 'A/V Distributio...') #1 /var/www/html/httpdocs/magento2/app/code/Fox/Seo/Observer/DiscontinuedCategoryCheck.php(51): Magento\Framework\Message\Manager->addError(Object(Magento\Framework\Phrase), 'A/V Distributio...') #2 /var/www/html/httpdocs/magento2/lib/internal/Magento/Framework/Event/Invoker/InvokerDefault.php(72): Fox\Seo\Observer\DiscontinuedCategoryCheck->execute(Object(Magento\Framework\Event\Observer)) #3 /var/www/html/httpdocs/magento2/lib/internal/Magento/Framework/Event/Invoker/InvokerDefault.php(60): Magento\Framework\Event\Invoker\InvokerDefault->_callObserverMethod(Object(Fox\Seo\Observer\DiscontinuedCategoryCheck), Object(Magento\Framework\Event\Observer in /var/www/html/httpdocs/magento2/lib/internal/Magento/Framework/Message/Manager.php on line 143