Bug report – PHP Fatal error: Uncaught TypeError – logic.php

SupportBug report – PHP Fatal error: Uncaught TypeError – logic.php
rszewczyk Staff asked 3 years ago
Symptom: While selecting a place, service and worker for service with set slot and block times, plugin crashes with TypeError Env: EA 3.10.0 WP 5.9.3 ERROR: [Tue May 10 17:58:25.436267 2022] [php:error] [pid 40288] [client ___] PHP Fatal error: Uncaught TypeError: Unsupported operand types: string * int in /usr/share/wordpress/wp-content/plugins/easy-appointments/src/logic.php:84\nStack trace:\n#0 /usr/share/wordpress/wp-content/plugins/easy-appointments/src/report.php(86): EALogic->get_open_slots()\n#1 /usr/share/wordpress/wp-content/plugins/easy-appointments/src/report.php(105): EAReport->get_whole_month_slots()\n#2 /usr/share/wordpress/wp-content/plugins/easy-appointments/src/ajax.php(685): EAReport->get_available_dates()\n#3 /usr/share/wordpress/wp-includes/class-wp-hook.php(307): EAAjax->ajax_month_status()\n#4 /usr/share/wordpress/wp-includes/class-wp-hook.php(331): WP_Hook->apply_filters()\n#5 /usr/share/wordpress/wp-includes/plugin.php(474): WP_Hook->do_action()\n#6 /usr/share/wordpress/wp-admin/admin-ajax.php(187): do_action()\n#7 {main}\n thrown in /usr/share/wordpress/wp-content/plugins/easy-appointments/src/logic.php on line 84, referer: https://_______.pl/umow/ TEMPORARY SOLUTION: Edit logic.php line 84 from: $block_time = $time_now + $block_before * 60; to: $block_time = $time_now + intval($block_before) * 60;
rszewczyk Staff replied 3 years ago

New version solved the issue. Thank you!

1 Answers
Best Answer
Nikola Loncar Staff answered 3 years ago
Thanks for report. It will be fixed right away. Best regards, Nikola
rszewczyk Staff replied 3 years ago

Thank you!

Nikola Loncar Staff replied 3 years ago

Hi, new version is live 🙂 thanks for reporting this issue.

Best regards,
Nikola

rszewczyk Staff replied 3 years ago

Thank you!