Fatal error: Uncaught ArgumentCountError
-
Hello,
I handle the community support for Sprout Invoices and one of our customers brought up that there is a conflict. I did happen to notice this causes the below Fatal Error causing issues displayed in the Sprout Invoices Log pages. I think the array for the tablenav_tabs is looking for the $post_type on every page. The workaround is to check for the null variable by changing the class-admin-tickets-list.php function.
Function Change:
public function tablenav_tabs( $post_type = 0, $which = 0) {Error in WordPress:
Fatal error: Uncaught ArgumentCountError: Too few arguments to function WPAS_Tickets_List::tablenav_tabs(), 1 passed in /home/sprout/primary/wp-includes/class-wp-hook.php on line 287 and exactly 2 expected in /home/sprout/primary/wp-content/plugins/awesome-support/includes/admin/class-admin-tickets-list.php:885 Stack trace: #0 /home/sprout/primary/wp-includes/class-wp-hook.php(287): WPAS_Tickets_List->tablenav_tabs('') #1 /home/sprout/primary/wp-includes/class-wp-hook.php(311): WP_Hook->apply_filters('', Array) #2 /home/sprout/primary/wp-includes/plugin.php(484): WP_Hook->do_action(Array) #3 /home/sprout/primary/wp-content/plugins/sprout-invoices-pro/controllers/records/Records_Admin_Table.php(109): do_action('restrict_manage...') #4 /home/sprout/primary/wp-admin/includes/class-wp-list-table.php(1326): SI_Records_Table->extra_tablenav('top') #5 /home/sprout/primary/wp-admin/includes/class-wp-list-table.php(1260): WP_List_Table->display_tablenav('top') #6 /home/sprout/primary/wp-content/plugins/sprout-invoices-pro/controll in /home/sprout/primary/wp-content/plugins/awesome-support/includes/admin/class-admin-tickets-list.php on line 885
Thanks
Elana D.
- The topic ‘Fatal error: Uncaught ArgumentCountError’ is closed to new replies.