Fatal error: Uncaught Error: Call to a member function getData() on null in /var/www/html/app/design/frontend/newdiya/theme/Sparx_Job/templates/email.phtml:7 Stack trace: #0 /var/www/html/vendor/magento/framework/View/TemplateEngine/Php.php(59): include() #1 /var/www/html/vendor/magento/framework/View/Element/Template.php(255): Magento\Framework\View\TemplateEngine\Php->render(Object(Sparx\Job\Block\Email), '/var/www/html/a...', Array) #2 /var/www/html/vendor/magento/framework/View/Element/Template.php(279): Magento\Framework\View\Element\Template->fetchView('/var/www/html/a...') #3 /var/www/html/vendor/magento/framework/View/Element/AbstractBlock.php(659): Magento\Framework\View\Element\Template->_toHtml() #4 /var/www/html/vendor/magento/framework/View/Layout.php(542): Magento\Framework\View\Element\AbstractBlock->toHtml() #5 /var/www/html/vendor/magento/framework/View/Layout.php(518): Magento\Framework\View\Layout->_renderBlock('job_email') #6 /var/www/html/var/generation/Magento/Framework/View/Layout/Interceptor.php(20 in /var/www/html/app/design/frontend/newdiya/theme/Sparx_Job/templates/email.phtml on line 7