Upgrade to PHP8 and get Fatal error: Uncaught TypeError: method_exists(): Argume
-
Hi
I changed PHP from 7.4 to 8 and all looks fine as far as I could tell until I went into orders and under column Quantity on all orders braking them so I cant see all products people have bought it sais:
Fatal error: Uncaught TypeError: method_exists(): Argument #1 ($object_or_class) must be of type object|string, null given in wp-content/plugins/woo-min-max-quantity-step-control-single/includes/set_max_min_quantity.php:58 Stack trace: #0 wp-content/plugins/woo-min-max-quantity-step-control-single/includes/set_max_min_quantity.php(58): method_exists() #1 wp-content/plugins/woo-min-max-quantity-step-control-single/includes/min-max-controller.php(152): wcmmq_check_quantity_in_cart() #2 wp-content/plugins/woo-min-max-quantity-step-control-single/includes/min-max-controller.php(122): WC_MMQ\Includes\Min_Max_Controller->assignInputArg() #3 wp-content/plugins/woo-min-max-quantity-step-control-single/includes/min-max-controller.php(371): WC_MMQ\Includes\Min_Max_Controller->organizeAndFinalizeArgs() #4 wp-includes/class-wp-hook.php(308): WC_MMQ\Includes\Min_Max_Controller->quantity_input_step() #5 wp-includes/plugin.php(205): WP_Hook->apply_filters() #6 wp-content/plugins/woocommerce/includes/admin/meta-boxes/views/html-order-item.php(70): apply_filters() #7 wp-content/plugins/woocommerce/includes/admin/meta-boxes/views/html-order-items.php(73): include(‘…’) #8 wp-content/plugins/woocommerce/includes/admin/meta-boxes/class-wc-meta-box-order-items.php(40): include(‘..’) #9 wp-admin/includes/template.php(1445): WC_Meta_Box_Order_Items::output() #10 wp-admin/edit-form-advanced.php(688): do_meta_boxes() #11 wp-admin/post.php(206): require(‘…’) #12 {main} thrown in?wp-content/plugins/woo-min-max-quantity-step-control-single/includes/set_max_min_quantity.php?on line?58
I switched back to PHP7.4 and all works well again.
Any suggestions on what I can do here to be able to go to PHP8?
Edit: I just noticed it was the min max plugin in the error I just posted. I guess I just had to write this all down in order to figure that out. Disabled that and all worked well.
- The topic ‘Upgrade to PHP8 and get Fatal error: Uncaught TypeError: method_exists(): Argume’ is closed to new replies.