Bug #3568 ยป 3568.patch
components/com_comprofiler/comprofiler.php | ||
---|---|---|
return;
|
||
}
|
||
|
||
$cbNotification = new cbNotification();
|
||
$res = $cbNotification->sendFromSystem($user_id,$subject,$message);
|
||
$_PLUGINS->trigger( 'onNewPassword', array($user_id,$newpass));
|
||
|
||
if ($res) {
|
||
$_PLUGINS->trigger( 'onNewPassword', array($user_id,$newpass));
|
||
$user = CBuser::getUserDataInstance( (int) $user_id );
|
||
$user->password = $newpass;
|
||
|
||
$user = CBuser::getUserDataInstance( (int) $user_id );
|
||
$user->password = $newpass;
|
||
if ( ! $user->storePassword() ) {
|
||
die("SQL error" . $user->getError());
|
||
}
|
||
cbRedirect( cbSef("index.php?option=$option&task=done".($Itemid ? "&Itemid=". (int) $Itemid : ""), false ), sprintf( _UE_NEWPASS_SENT, htmlspecialchars( $confirmEmail ) ) );
|
||
if ( ! $user->storePassword() ) {
|
||
cbRedirect( cbSef("index.php?option=$option&task=lostPassword".($Itemid ? "&Itemid=". (int) $Itemid : ""), false ), $user->getError(), 'error' );
|
||
return;
|
||
} else {
|
||
cbRedirect( cbSef("index.php?option=$option&task=done".($Itemid ? "&Itemid=". (int) $Itemid : ""), false ),_UE_NEWPASS_FAILED );
|
||
$cbNotification = new cbNotification();
|
||
$res = $cbNotification->sendFromSystem($user_id,$subject,$message);
|
||
|
||
if ( ! $res ) {
|
||
cbRedirect( cbSef("index.php?option=$option&task=done".($Itemid ? "&Itemid=". (int) $Itemid : ""), false ),_UE_NEWPASS_FAILED );
|
||
return;
|
||
}
|
||
}
|
||
cbRedirect( cbSef("index.php?option=$option&task=done".($Itemid ? "&Itemid=". (int) $Itemid : ""), false ), sprintf( _UE_NEWPASS_SENT, htmlspecialchars( $confirmEmail ) ) );
|
||
} else {
|
||
cbRedirect( cbSef("index.php?option=$option&task=done".($Itemid ? "&Itemid=". (int) $Itemid : ""), false ), _UE_NEWPASS_FAILED );
|
||
}
|