{"id":365,"date":"2019-04-01T06:29:17","date_gmt":"2019-04-01T06:29:17","guid":{"rendered":"https:\/\/meetanshi.com\/blog\/2019\/04\/01\/solved-uncaught-error-call-to-a-member-function-getpackage-magento-2-3-0\/"},"modified":"2025-07-17T10:41:15","modified_gmt":"2025-07-17T05:11:15","slug":"solved-uncaught-error-call-to-a-member-function-getpackage-magento-2-3-0","status":"publish","type":"post","link":"https:\/\/meetanshi.com\/blog\/solved-uncaught-error-call-to-a-member-function-getpackage-magento-2-3-0\/","title":{"rendered":"Solved: &#8220;Uncaught Error: Call to a member function getPackage()&#8221; [Magento 2.3.0]"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\"><a href=\"https:\/\/meetanshi.com\/blog\/magento-2-3-release\/\" target=\"_blank\" rel=\"noreferrer noopener\">Magento 2.3.0<\/a> was released on November 28, 2018. Owing to the excellent features it offered, the Magento 2 store owners were bound to upgrade their store to the latest version!<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">However, some of them faced a theme error <i><strong>&#8220;Uncaught Error: Call to a member function getPackage()&#8221;<\/strong><\/i>&nbsp;<i><strong>in Magento 2.3. 0<\/strong><\/i> while static content deployment. If you are one of them, you may have seen an error like this when you run the command:<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>php bin\/magento setup:static-content:deploy -f<\/strong><\/p>\n\n\n\n<figure class=\"wp-block-image\"><img decoding=\"async\" src=\"https:\/\/meetanshi.com\/blog\/wp-content\/uploads\/2019\/04\/Static-content-deployment-error.png\" alt=\"Static content deployment error in Magento 2.3.0\" class=\"wp-image-4740\"\/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">If that&#8217;s the case, continue reading for the solution!<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Methods to solve &#8220;Uncaught Error: Call to a member function getPackage()&#8221; in Magento 2.3.0:<\/h2>\n\n\n\n<h3 class=\"wp-block-heading\">Method 1:<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Run the below command<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>rm -rf pub\/static\/* var\/view_preprocessed\/pub\/*<br>php bin\/magento setup:static-content:deploy -f<\/strong><\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Method 2:<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">email.css and email-inline.css are available in &nbsp;your custom theme<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Open that css file and replace the code:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">@import url(\"{{base_url_path}}frontend\/Magento\/luma\/{{locale}}\/css\/email-fonts.css\");&amp;nbsp;<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">with,<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">@import url(\"{{baseUrl}}\/css\/email-fonts.css\");<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Run the below command:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code><strong>php bin\/magento setup:static-content:deploy -f<\/strong><\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">With any of the above methods, you can solve this theme-related error in Magento 2.3.0<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Thank you.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Magento 2.3.0 was released on November 28, 2018. Owing to the excellent features it offered, the Magento 2 store owners were bound to upgrade their&#8230;<\/p>\n","protected":false},"author":5,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[34],"tags":[],"class_list":["post-365","post","type-post","status-publish","format-standard","hentry","category-magento"],"acf":[],"_links":{"self":[{"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/posts\/365","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/users\/5"}],"replies":[{"embeddable":true,"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/comments?post=365"}],"version-history":[{"count":2,"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/posts\/365\/revisions"}],"predecessor-version":[{"id":15483,"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/posts\/365\/revisions\/15483"}],"wp:attachment":[{"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/media?parent=365"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/categories?post=365"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/meetanshi.com\/blog\/wp-json\/wp\/v2\/tags?post=365"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}