5
votes

I am using Porto v2.2.0 – Ultimate Responsive Magento Theme and showing error like

knockout.js:3012 Uncaught TypeError: Unable to process binding "css: function (){return { empty:cart().summary_count == 0} }"
Message: cart is not a function
1
Share your model, seems like cart is not an ko.observable, function or computed field - frankfg

1 Answers

6
votes

I have resolved it in three steps:

  1. Replace the minicart.phtml file from theme (app\design\frontend\Theme_namespace\Theme_module\Magento_Ch‌​eckout\templates\car‌​t) with core template (vendor\magento\module-checkout\view\frontend\templates\cart‌​).

  2. Replace content.html file from your theme (app\design\frontend\Theme_namespace\Theme_module\Magento_Checkout\web\template\minicart\content.html) with core template (vendor\magento\module-checkout\view\frontend\web\template\minicart\content.html)

  3. Remove all pub/static/frontend , remove var folder. Run deploy static content again : php magento setup:static-content:deploy

Result minicart after fixed :

enter image description here