Fix delete of member

This commit is contained in:
Laurent Destailleur 2022-12-08 14:26:33 +01:00
parent bb406f66be
commit 5f3e231d13
2 changed files with 3 additions and 2 deletions

View File

@ -620,7 +620,8 @@ if (empty($reshook)) {
if ($user->hasRight('adherent', 'supprimer') && $action == 'confirm_delete' && $confirm == 'yes') {
$result = $object->delete($id, $user);
if ($result > 0) {
if (!empty($backtopage)) {
setEventMessages($langs->trans("RecordDeleted"), null, 'errors');
if (!empty($backtopage) && !preg_match('/'.preg_quote($_SERVER["PHP_SELF"], '/').'/', $backtopage)) {
header("Location: ".$backtopage);
exit;
} else {

View File

@ -4999,7 +4999,7 @@ class Form
{
global $langs, $conf;
$more = '<!-- formconfirm before calling page='.dol_escape_htmltag($page).' -->';
$more = '<!-- formconfirm - before call, page='.dol_escape_htmltag($page).' -->';
$formconfirm = '';
$inputok = array();
$inputko = array();