Skip to content

Commit

Permalink
Merge pull request #4993 from Deltik/fix/4991
Browse files Browse the repository at this point in the history
Fixes #4991: Improper array access in sc_signup_extended_user_fields
  • Loading branch information
CaMer0n authored Apr 21, 2023
2 parents 3b4c583 + 1e601fb commit 198d0cf
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion e107_core/shortcodes/batch/signup_shortcodes.php
Original file line number Diff line number Diff line change
Expand Up @@ -520,6 +520,7 @@ function sc_signup_extended_user_fields($parm = null)
{
$opts = $parm;
$required = (int) $ext['user_extended_struct_required'];
$edit = isset($_POST['ue']['user_' . $ext['user_extended_struct_name']]) ? $_POST['ue']['user_' . $ext['user_extended_struct_name']] : '';

if($required === 0) // "No - Will not show on Signup page".
{
Expand All @@ -545,7 +546,7 @@ function sc_signup_extended_user_fields($parm = null)
$replace = array(
$label,
($required === 1 ? $this->sc_signup_is_mandatory('true') : ''),
$ue->renderElement($ext, varset($_POST['ue']['user_' . $ext['user_extended_struct_name']]), $opts)
$ue->renderElement($ext, $edit, $opts)
);

$text .= str_replace($search, $replace, $this->template['extended-user-fields']);
Expand Down

0 comments on commit 198d0cf

Please sign in to comment.