Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fatal Error when WooCommerce is disabled and Accommodation Bookings is enabled with Booking. #363

Closed
ankitguptaindia opened this issue Aug 31, 2023 · 0 comments · Fixed by #367
Assignees
Labels
priority: high The issue/PR is high priority—it affects lots of customers substantially, but not critically.
Milestone

Comments

@ankitguptaindia
Copy link
Member

ankitguptaindia commented Aug 31, 2023

Getting a fatal error when WooCommerce is disabled and Accommodation-Bookings is enabled with Booking.

PHP Fatal error:  Uncaught Error: Class "WC_Settings_API" not found in /Users/ank/Local Sites/woolocal/app/public/wp-content/plugins/woocommerce-accommodation-bookings-2/includes/admin/class-wc-accommodation-booking-admin-product-settings.php:8
Stack trace:
#0 /Users/ank/Local Sites/woolocal/app/public/wp-content/plugins/woocommerce-accommodation-bookings-2/includes/class-wc-accommodation-bookings-plugin.php(209): include()
#1 /Users/ank/Local Sites/woolocal/app/public/wp-includes/class-wp-hook.php(310): WC_Accommodation_Bookings_Plugin->admin_includes('')
#2 /Users/ank/Local Sites/woolocal/app/public/wp-includes/class-wp-hook.php(334): WP_Hook->apply_filters(NULL, Array)
#3 /Users/ank/Local Sites/woolocal/app/public/wp-includes/plugin.php(517): WP_Hook->do_action(Array)
#4 /Users/ank/Local Sites/woolocal/app/public/wp-settings.php(632): do_action('init')
#5 /Users/ank/Local Sites/woolocal/app/public/wp-config.php(101): require_once('/Users/ank/Loca...')
#6 /Users/ank/Local Sites/woolocal/app/public/wp-load.php(50): require_once('/Users/ank/Loca...')
#7 /Users/ank/Local Sites/woolocal/app/public/wp-admin/admin.php(34): require_once('/Users/ank/Loca...')
#8 /Users/ank/Local Sites/woolocal/app/public/wp-admin/plugins.php(10): require_once('/Users/ank/Loca...')
#9 {main}
  thrown in /Users/ank/Local Sites/woolocal/app/public/wp-content/plugins/woocommerce-accommodation-bookings-2/includes/admin/class-wc-accommodation-booking-admin-product-settings.php on line 8

Steps-

  1. Activate WC, WC Booking and Accommodation-Bookings.
  2. Deactivate WC
  3. A fatal error will appear.

Note that if Booking is disabled before the WC then Fatal error will not appear.

Environment:

WordPress Environment

WordPress address (URL): https://woolocal.local
Site address (URL): https://woolocal.local
WC Version: 8.0.3
REST API Version: ✔ 8.0.3
WC Blocks Version: ✔ 11.0.0
Action Scheduler Version: ✔ 3.6.1
Log Directory Writable: ✔
WP Version: 6.3.1
WP Multisite: –
WP Memory Limit: 256 MB
WP Debug Mode: ✔
WP Cron: ✔
Language: en_US
External object cache: –

Server Environment

Server Info: nginx/1.16.0
PHP Version: 8.0.22
PHP Post Max Size: 1,000 MB
PHP Time Limit: 1200
PHP Max Input Vars: 4000
cURL Version: 7.84.0
(SecureTransport) OpenSSL/1.1.1q

fatal.error.mp4

Tasks

No tasks being tracked yet.
@ankitguptaindia ankitguptaindia added type: bug The issue is a confirmed bug. priority: low The issue/PR is low priority—not many people are affected or there’s a workaround, etc. and removed type: bug The issue is a confirmed bug. labels Aug 31, 2023
@vikrampm1 vikrampm1 added priority: high The issue/PR is high priority—it affects lots of customers substantially, but not critically. and removed priority: low The issue/PR is low priority—not many people are affected or there’s a workaround, etc. labels Sep 1, 2023
@faisal-alvi faisal-alvi self-assigned this Sep 1, 2023
@faisal-alvi faisal-alvi added this to the Future Release milestone Sep 1, 2023
@vikrampm1 vikrampm1 modified the milestones: Future Release, 1.2.1 Oct 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
priority: high The issue/PR is high priority—it affects lots of customers substantially, but not critically.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants