[go: up one dir, main page]

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

Calendar bug passing string to abs() in add edit event #7674

Open
juggernautsei opened this issue Aug 15, 2024 · 0 comments
Open

Calendar bug passing string to abs() in add edit event #7674

juggernautsei opened this issue Aug 15, 2024 · 0 comments

Comments

@juggernautsei
Copy link
Member

Describe the bug

Uncaught TypeError: abs(): Argument #1 ($num) must be of type int|float, string given in /var/www/html/boss/interface/main/calendar/add_edit_event.php:348

To Reproduce

create and appointment on the calendar.

Proposed solution

cast form duration to int.

if (is_int($_POST['form_duration'])) {
$form_duration = (int) $_POST['form_duration'];
} else {
$form_duration = $_POST['form_duration'];
}
$duration = abs($form_duration);

Client configuration

  • Browser: Chrome
  • OpenEMR version: 7.0.0 (1)
  • Operating system: Ubuntu
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant