EM_Gateways::get_customer_field() returns all fields when field not found
-
When calling EM_Gateways::get_customer_field() with a
$field_name
that does not exist, an array of all values is returned. This happens because$form_field_id
has no value when$field_name
is not found, triggering an undefined variable warning and retrieving all registration values instead of a selected value.NB: I only hit this because my eWAY payment integration uses the standard address fields from the booking, and some people delete some fields (e.g. Country) because they don’t require them.
Also: I notice that when the person booking for the event is logged in and has a value defined, that value takes precedence over whatever is entered in the form — which might be an issue if the logged in user is booking on behalf of someone else.
cheers,
Ross
- The topic ‘EM_Gateways::get_customer_field() returns all fields when field not found’ is closed to new replies.