On the confirmation after making an appointment the following notice occurs:

Notice: Undefined variable: expired in AppointmentsClientApi->call() (regel 86 van */profiles/dvg/modules/contrib/dvg_appointments/dvg_appointments.client.inc).Notice: Undefined variable: expired in AppointmentsClientApi->call() (regel 86 van */profiles/dvg/modules/contrib/dvg_appointments/dvg_appointments.client.inc).

Confirmed with the AppointmentsGPlanMultipleClient, not tested with other setups.

Comments

TVoesenek created an issue. See original summary.

joshahubbers’s picture

StatusFileSize
new717 bytes

We used a variable that was set within a if() condition, but not initialized. So if the condition was not met, the variable was not available. This patch initializes the variable, before it is altered in the if() condition.

joshahubbers’s picture

Status: Active » Needs review
paulvandenburg’s picture

StatusFileSize
new781 bytes
new1.19 KB

The solution is good, but the location could be better.
Further up the function the $expired value is defined, if there is a cache. The current solution now always overwrites that (possible) value.
Better would be to only set the variable if that possible var set is not done.

See attached patch.

joshahubbers’s picture

Status: Needs review » Reviewed & tested by the community

  • paulvandenburg committed 7cad971 on 7.x-1.x
    Issue #3045572 by paulvandenburg, JoshaHubbers: Notice on confirmation...
paulvandenburg’s picture

Status: Reviewed & tested by the community » Fixed

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.