Title: Problem with widget
Last modified: July 21, 2021

---

# Problem with widget

 *  Resolved [nickyfulls](https://wordpress.org/support/users/nickyfulls/)
 * (@nickyfulls)
 * [4 years, 9 months ago](https://wordpress.org/support/topic/problem-with-widget-15/)
 * `I can’t open the widget that reports this error or bug to me:
 * Fatal error: Uncaught Error: Call to a member function get_cart() on null in /
   usr/www/users/xyz/wp-content/themes/vino/framework/modules/woocommerce/widgets/
   woocommerce-dropdown-cart.php:113 Stack trace: #0 /usr/www/users/xyz/wp-includes/
   class-wp-widget.php(393): VinoElatedClassWoocommerceDropdownCart->widget(Array,
   Array) #1 /usr/www/users/xyz/wp-includes/widgets.php(1977): WP_Widget->display_callback(
   Array, Array) #2 /usr/www/users/xyz/wp-includes/rest-api/endpoints/class-wp-rest-
   widgets-controller.php(630): wp_render_widget(‘eltdf_woocommer…’, ‘eltdf-header-
   wi…’) #3 /usr/www/users/xyz/wp-includes/rest-api/endpoints/class-wp-rest-widgets-
   controller.php(122): WP_REST_Widgets_Controller->prepare_item_for_response(Array,
   Object(WP_REST_Request)) #4 /usr/www/users/xyz/wp-includes/rest-api/class-wp-
   rest-server.php(1140): WP_REST_Widgets_Controller->get_items(Object(WP_REST_Request))#
   5 /usr/www/users/xyz/wp-includes/rest-api/class-wp-rest-server.php(987): WP_REST_Server-
   >respond_to_request(Object(WP_ in /usr/www/users/xyz/wp-content/themes/vino/framework/
   modules/woocommerce/widgets/woocommerce-dropdown-cart.php on line 113
 * What is it ? Could you fix it?

Viewing 10 replies - 1 through 10 (of 10 total)

 *  Plugin Support [Tseten a11n](https://wordpress.org/support/users/tibetanitech/)
 * (@tibetanitech)
 * [4 years, 9 months ago](https://wordpress.org/support/topic/problem-with-widget-15/#post-14685896)
 * Do you mean you see this error when you open the Widgets page?
 * Could you also please share a copy of your site’s System Status? You can find
   it via WooCommerce > Status. Select “Get system report” and then “Copy for support”.
   Once you’ve done that, paste it here in your response.
 *  Thread Starter [nickyfulls](https://wordpress.org/support/users/nickyfulls/)
 * (@nickyfulls)
 * [4 years, 9 months ago](https://wordpress.org/support/topic/problem-with-widget-15/#post-14685954)
 * **Yes when I open the widget page I see this error.**
 * ### WordPress Environment ###
 * WordPress address (URL): [https://xyz.it](https://xyz.it)
    Site address (URL):
   [https://xyz.it](https://xyz.it) WC Version: 5.5.1 REST API Version: ✔ 5.5.1 
   WC Blocks Version: ✔ 5.3.2 Action Scheduler Version: ✔ 3.2.1 WC Admin Version:
   ✔ 2.4.1 Log Directory Writable: ✔ WP Version: 5.8 WP Multisite: – WP Memory Limit:
   256 MB WP Debug Mode: – WP Cron: ✔ Language: en_US External object cache: –
 * ### Server Environment ###
 * Server Info: Apache
    PHP Version: 7.4.21 PHP Post Max Size: 256 MB PHP Time Limit:
   300 PHP Max Input Vars: 5000 cURL Version: 7.64.0 OpenSSL/1.1.1d
 * SUHOSIN Installed: –
    MySQL Version: 5.7.34-2 Max Upload Size: 128 MB Default
   Timezone is UTC: ✔ fsockopen/cURL: ✔ SoapClient: ✔ DOMDocument: ✔ GZip: ✔ Multibyte
   String: ✔ Remote Post: ✔ Remote Get: ✔
 * ### Database ###
 * WC Database Version: 5.5.1
    WC Database Prefix: wp_ Dimensione totale database:
   23.61MB Dimensione dati database: 16.39MB Dimensione indice database: 7.22MB 
   wp_woocommerce_sessions: Dati: 0.02MB + indice: 0.02MB + motore InnoDB wp_woocommerce_api_keys:
   Dati: 0.02MB + indice: 0.03MB + motore InnoDB wp_woocommerce_attribute_taxonomies:
   Dati: 0.02MB + indice: 0.02MB + motore InnoDB wp_woocommerce_downloadable_product_permissions:
   Dati: 0.02MB + indice: 0.06MB + motore InnoDB wp_woocommerce_order_items: Dati:
   0.02MB + indice: 0.02MB + motore InnoDB wp_woocommerce_order_itemmeta: Dati: 
   0.02MB + indice: 0.03MB + motore InnoDB wp_woocommerce_tax_rates: Dati: 0.02MB
   + indice: 0.06MB + motore InnoDB wp_woocommerce_tax_rate_locations: Dati: 0.02MB
   + indice: 0.03MB + motore InnoDB wp_woocommerce_shipping_zones: Dati: 0.02MB 
   + indice: 0.00MB + motore InnoDB wp_woocommerce_shipping_zone_locations: Dati:
   0.02MB + indice: 0.03MB + motore InnoDB wp_woocommerce_shipping_zone_methods:
   Dati: 0.02MB + indice: 0.00MB + motore InnoDB wp_woocommerce_payment_tokens: 
   Dati: 0.02MB + indice: 0.02MB + motore InnoDB wp_woocommerce_payment_tokenmeta:
   Dati: 0.02MB + indice: 0.03MB + motore InnoDB wp_woocommerce_log: Dati: 0.02MB
   + indice: 0.02MB + motore InnoDB wp_actionscheduler_actions: Dati: 0.05MB + indice:
   0.13MB + motore InnoDB wp_actionscheduler_claims: Dati: 0.02MB + indice: 0.02MB
   + motore InnoDB wp_actionscheduler_groups: Dati: 0.02MB + indice: 0.02MB + motore
   InnoDB wp_actionscheduler_logs: Dati: 0.02MB + indice: 0.03MB + motore InnoDB
   wp_commentmeta: Dati: 0.02MB + indice: 0.03MB + motore InnoDB wp_comments: Dati:
   0.02MB + indice: 0.09MB + motore InnoDB wp_links: Dati: 0.02MB + indice: 0.02MB
   + motore InnoDB wp_options: Dati: 3.03MB + indice: 0.08MB + motore InnoDB wp_postmeta:
   Dati: 8.52MB + indice: 5.64MB + motore InnoDB wp_posts: Dati: 2.34MB + indice:
   0.22MB + motore InnoDB wp_revslider_css: Dati: 0.13MB + indice: 0.00MB + motore
   InnoDB wp_revslider_css_bkp: Dati: 0.02MB + indice: 0.00MB + motore InnoDB wp_revslider_layer_animations:
   Dati: 0.02MB + indice: 0.00MB + motore InnoDB wp_revslider_layer_animations_bkp:
   Dati: 0.02MB + indice: 0.00MB + motore InnoDB wp_revslider_navigations: Dati:
   0.02MB + indice: 0.00MB + motore InnoDB wp_revslider_navigations_bkp: Dati: 0.02MB
   + indice: 0.00MB + motore InnoDB wp_revslider_sliders: Dati: 0.11MB + indice:
   0.00MB + motore InnoDB wp_revslider_sliders_bkp: Dati: 0.02MB + indice: 0.00MB
   + motore InnoDB wp_revslider_slides: Dati: 1.19MB + indice: 0.00MB + motore InnoDB
   wp_revslider_slides_bkp: Dati: 0.02MB + indice: 0.00MB + motore InnoDB wp_revslider_static_slides:
   Dati: 0.02MB + indice: 0.00MB + motore InnoDB wp_revslider_static_slides_bkp:
   Dati: 0.02MB + indice: 0.00MB + motore InnoDB wp_termmeta: Dati: 0.02MB + indice:
   0.03MB + motore InnoDB wp_terms: Dati: 0.02MB + indice: 0.03MB + motore InnoDB
   wp_term_relationships: Dati: 0.02MB + indice: 0.02MB + motore InnoDB wp_term_taxonomy:
   Dati: 0.02MB + indice: 0.03MB + motore InnoDB wp_usermeta: Dati: 0.02MB + indice:
   0.03MB + motore InnoDB wp_users: Dati: 0.02MB + indice: 0.05MB + motore InnoDB
   wp_wc_admin_notes: Dati: 0.02MB + indice: 0.00MB + motore InnoDB wp_wc_admin_note_actions:
   Dati: 0.02MB + indice: 0.02MB + motore InnoDB wp_wc_category_lookup: Dati: 0.02MB
   + indice: 0.00MB + motore InnoDB wp_wc_customer_lookup: Dati: 0.02MB + indice:
   0.03MB + motore InnoDB wp_wc_download_log: Dati: 0.02MB + indice: 0.03MB + motore
   InnoDB wp_wc_order_coupon_lookup: Dati: 0.02MB + indice: 0.03MB + motore InnoDB
   wp_wc_order_product_lookup: Dati: 0.02MB + indice: 0.06MB + motore InnoDB wp_wc_order_stats:
   Dati: 0.02MB + indice: 0.05MB + motore InnoDB wp_wc_order_tax_lookup: Dati: 0.02MB
   + indice: 0.03MB + motore InnoDB wp_wc_product_meta_lookup: Dati: 0.02MB + indice:
   0.09MB + motore InnoDB wp_wc_reserved_stock: Dati: 0.02MB + indice: 0.00MB + 
   motore InnoDB wp_wc_tax_rate_classes: Dati: 0.02MB + indice: 0.02MB + motore 
   InnoDB wp_wc_webhooks: Dati: 0.02MB + indice: 0.02MB + motore InnoDB wp_wpforms_tasks_meta:
   Dati: 0.02MB + indice: 0.00MB + motore InnoDB wp_wpmailsmtp_tasks_meta: Dati:
   0.02MB + indice: 0.00MB + motore InnoDB wp_wpmm_subscribers: Dati: 0.02MB + indice:
   0.00MB + motore InnoDB
 * ### Post Type Counts ###
 * attachment: 447
    custom_css: 1 customize_changeset: 46 nav_menu_item: 29 page:
   95 portfolio-item: 26 post: 6 product: 14 revision: 197 shop_order: 1 testimonials:
   11 wpcf7_contact_form: 1
 * ### Security ###
 * Secure connection (HTTPS): ✔
    Hide errors from visitors: ✔
 * ### Active Plugins (18) ###
 * Akismet Anti-Spam: by Automattic – 4.1.10
    Contact Form 7: by Takayuki Miyoshi–
   5.4.2 Yoast Duplicate Post: by Enrico Battocchi & Team Yoast – 4.1.2 Easy remove
   item menu: by Camilo – 1.0.6 Elated CPT: by Elated Themes – 1.3.1 Elated Instagram
   Feed: by Elated Themes – 2.0 Elated Twitter Feed: by Elated Themes – 1.0.1 Envato
   Market: by Envato – 2.0.6 Cookie and Consent Solution for the GDPR & ePrivacy:
   by iubenda – 2.5.4 WPBakery Page Builder: by Michael M – WPBakery.com – 6.4.1
   Slider Revolution: by ThemePunch – 6.2.23 TablePress: by Tobias Bäthge – 1.14
   WooCommerce PayPal Payments: by WooCommerce – 1.3.2 WooCommerce: by Automattic–
   5.5.1 Importatore WordPress: by wordpressdotorg – 0.7 WP Mail SMTP: by WPForms–
   2.9.0 WP Maintenance Mode: by Designmodo – 2.4.1 WPForms Lite: by WPForms – 1.6.8.1
 * ### Inactive Plugins (0) ###
 * ### Settings ###
 * API Enabled: –
    Force SSL: – Currency: EUR (€) Currency Position: left Thousand
   Separator: , Decimal Separator: . Number of Decimals: 2 Taxonomies: Product Types:
   external (external) grouped (grouped) simple (simple) variable (variable)
 * Taxonomies: Product Visibility: exclude-from-catalog (exclude-from-catalog)
    
   exclude-from-search (exclude-from-search) featured (featured) outofstock (outofstock)
   outofstock (outofstock-2) rated-1 (rated-1) rated-2 (rated-2) rated-3 (rated-
   3) rated-3 (rated-3-2) rated-4 (rated-4) rated-5 (rated-5) rated-5 (rated-5-2)
 * Connected to WooCommerce.com: –
 * ### WC Pages ###
 * Shop base: #7 – /shop/
    Carrello: #8 – /cart/ Pagamento: #9 – /checkout/ Il mio
   account: #10 – /my-account/ Termini e condizioni: ❌ La pagina non è impostata
 * ### Theme ###
 * Name: Vino
    Version: 1.7.1 Author URL: [http://themeforest.net/user/elated-themes](http://themeforest.net/user/elated-themes)
   Child Theme: ❌ – Se stai modificando WooCommerce o un tema genitore che non 
   hai costruito personalmente ti consigliamo di utilizzare un tema child. Vedi:
   Come creare un tema child
 * WooCommerce Support: ✔
 * ### Templates ###
 * Archive Template: Il tuo tema ha il file woocommerce.php
    non potrai sovrascrivere
   il template personalizzato woocommerce/archive-product.php poiché woocommerce.
   php ha priorità su archive-product.php. Questo serve a prevenire problemi di 
   visualizzazione.
 * Overrides: vino/woocommerce/content-product.php
    vino/woocommerce/global/quantity-
   input.php vino/product-searchform.php
 * ### Action Scheduler ###
 * Completato: 61
    Oldest: 2021-07-14 20:32:06 +0200 Newest: 2021-07-21 15:43:09
   +0200
 * In attesa: 5
    Oldest: 2021-07-22 02:10:55 +0200 Newest: 2021-07-24 19:25:40 +
   0200
 * ### Status report information ###
 * Generated at: 2021-07-21 19:35:11 +02:00
    `
 *  [dheniellguimaraes](https://wordpress.org/support/users/dheniellguimaraes/)
 * (@dheniellguimaraes)
 * [4 years, 9 months ago](https://wordpress.org/support/topic/problem-with-widget-15/#post-14686859)
 * I also have the same problem.
 *     ```
       <?php biagiotti_mikado_get_module_template_part( 'widgets/woocommerce-dropdown-cart/templates/parts/opener', 'woocommerce' ); ?>
       <div class="mkdf-sc-dropdown">
       	<div class="mkdf-sc-dropdown-inner">
       		<?php  if ( sv_wc_is_category_alone_in_cart( $category ) && ! WC()->cart->is_empty() ) { // <= <=
       			biagiotti_mikado_get_module_template_part( 'widgets/woocommerce-dropdown-cart/templates/parts/loop', 'woocommerce' );
   
       			biagiotti_mikado_get_module_template_part( 'widgets/woocommerce-dropdown-cart/templates/parts/order-details', 'woocommerce' );
   
       			biagiotti_mikado_get_module_template_part( 'widgets/woocommerce-dropdown-cart/templates/parts/button', 'woocommerce' );
       		} else {
       			biagiotti_mikado_get_module_template_part( 'widgets/woocommerce-dropdown-cart/templates/posts-not-found', 'woocommerce' );
       		} ?>
       	</div>
       </div>
       ```
   
 * The affected line is
 * <?php if ( sv_wc_is_category_alone_in_cart( $category ) && ! WC()->cart->is_empty()){//
   <= <=
 *  Plugin Support [Gabriel – a11n](https://wordpress.org/support/users/gabrielfuentes/)
 * (@gabrielfuentes)
 * [4 years, 9 months ago](https://wordpress.org/support/topic/problem-with-widget-15/#post-14686995)
 * Hi [@nickyfulls](https://wordpress.org/support/users/nickyfulls/) 👋
 * > `Fatal error: Uncaught Error: Call to a member function get_cart() on null 
   > in /usr/www/users/xyz/wpcontent/themes/<strong>vino</strong>/framework/modules/
   > woocommerce/widgets/woocommerce-dropdown-cart.php:113`
 * I want to let you know that the error that you are receiving is coming from your
   theme **Vino**.
 * This kind of problem is usually caused by a conflict with your theme or with 
   another plugin.
      The best way to determine this is to:
    - Temporarily switch your theme to [Storefront](https://www.woocommerce.com/storefront/)
    - Disable all plugins except for WooCommerce
    - Repeat the action that is causing the problem
 * If you’re not seeing the same problem after completing the conflict test, then
   you know the problem was with the plugins and/or theme you deactivated. To figure
   out which plugin is causing the problem, reactivate your other plugins one by
   one, testing after each until you find the one causing conflict. [You can find a more detailed explanation on how to do a conflict test here.](https://docs.woocommerce.com/document/how-to-test-for-conflicts/)
 * **Before you start**
 * First, please make sure you have a good backup in place of your full site and
   database.
 * Second, I would suggest installing a plugin called Health Check & Troubleshooting.
   This is a plugin developed by the WordPress community and it allows you to disable
   plugins without affecting your current site visitors.
 * If the issue gets fixed when changing your theme to the **Storefront**, then 
   please reach out to your theme support team as they are the best equipped to 
   help you out.
 * Cheers!
 *  Plugin Support [Gabriel – a11n](https://wordpress.org/support/users/gabrielfuentes/)
 * (@gabrielfuentes)
 * [4 years, 9 months ago](https://wordpress.org/support/topic/problem-with-widget-15/#post-14686997)
 * Hey [@dheniellguimaraes](https://wordpress.org/support/users/dheniellguimaraes/)
   👋
 * Please create a new topic so that we can help you there.
 * Cheers.
 *  [David Gallagher](https://wordpress.org/support/users/gallagher/)
 * (@gallagher)
 * [4 years, 9 months ago](https://wordpress.org/support/topic/problem-with-widget-15/#post-14688017)
 * This seems to be a problem with a few themes all made using a shared framework.
   The issue is related to the new WordPress widgets screen.
 * I was able to access the widgets screen again by installing the new “Classic 
   Widgets” plugin.
 *  Thread Starter [nickyfulls](https://wordpress.org/support/users/nickyfulls/)
 * (@nickyfulls)
 * [4 years, 9 months ago](https://wordpress.org/support/topic/problem-with-widget-15/#post-14692406)
 * I would like to know in order not to have these problems of updates among which
   templates you recommend for an e-commerce.
 *  [tresaury](https://wordpress.org/support/users/tresaury/)
 * (@tresaury)
 * [4 years, 9 months ago](https://wordpress.org/support/topic/problem-with-widget-15/#post-14706329)
 * Hi, I have the same problem with the same widget, my theme is Endurer:
 * Error: Call to a member function get_cart() on null in /home/…/www/wp-content/
   themes/endurer/framework/modules/woocommerce/widgets/woocommerce-dropdown-cart/
   woocommerce-dropdown-cart.php:38
 * Did WordPress will make an update to fix this incompatibility or should we have
   to use the “classic widget” plugin forever ?
 *  [Mirko P.](https://wordpress.org/support/users/rainfallnixfig/)
 * (@rainfallnixfig)
 * [4 years, 9 months ago](https://wordpress.org/support/topic/problem-with-widget-15/#post-14707906)
 * Hi [@nickyfulls](https://wordpress.org/support/users/nickyfulls/),
 * > I would like to know in order not to have these problems of updates among which
   > templates you recommend for an e-commerce.
 * We’d recommend visiting the WooCommerce Themes Showcase to find the perfect design
   for your store here:
 * [https://woocommerce.com/product-category/themes/](https://woocommerce.com/product-category/themes/)
 * [@tresaury](https://wordpress.org/support/users/tresaury/) Please open a new 
   separate thread and we’ll be happy to help you there.
 * Thanks!
 *  Plugin Support [Gabriel – a11n](https://wordpress.org/support/users/gabrielfuentes/)
 * (@gabrielfuentes)
 * [4 years, 9 months ago](https://wordpress.org/support/topic/problem-with-widget-15/#post-14732299)
 * We’ve not seen any activity on this thread for a while, so I’m marking this thread
   as resolved.
 * Hopefully, you were able to find a solution to your problem! If you have further
   questions, please feel free to open a new topic.
 * Cheers!

Viewing 10 replies - 1 through 10 (of 10 total)

The topic ‘Problem with widget’ is closed to new replies.

 * ![](https://ps.w.org/woocommerce/assets/icon.svg?rev=3234504)
 * [WooCommerce](https://wordpress.org/plugins/woocommerce/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/woocommerce/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/woocommerce/)
 * [Active Topics](https://wordpress.org/support/plugin/woocommerce/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/woocommerce/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/woocommerce/reviews/)

 * 10 replies
 * 7 participants
 * Last reply from: [Gabriel – a11n](https://wordpress.org/support/users/gabrielfuentes/)
 * Last activity: [4 years, 9 months ago](https://wordpress.org/support/topic/problem-with-widget-15/#post-14732299)
 * Status: resolved