Fix: Bad action reset

This commit is contained in:
Laurent Destailleur 2012-05-23 17:49:08 +02:00
parent 190bcf61e4
commit 95b976c3d5

View File

@ -150,7 +150,9 @@ if ($action == 'add' && $user->rights->ecm->setup)
} }
// Remove file // Remove file
if ($action == 'confirm_deletefile' && GETPOST('confirm') == 'yes') if ($action == 'confirm_deletefile')
{
if (GETPOST('confirm') == 'yes')
{ {
$result=$ecmdir->fetch($section); $result=$ecmdir->fetch($section);
if (! $result > 0) if (! $result > 0)
@ -167,10 +169,11 @@ if ($action == 'confirm_deletefile' && GETPOST('confirm') == 'yes')
$mesg = '<div class="ok">'.$langs->trans("FileWasRemoved").'</div>'; $mesg = '<div class="ok">'.$langs->trans("FileWasRemoved").'</div>';
$result=$ecmdir->changeNbOfFiles('-'); $result=$ecmdir->changeNbOfFiles('-');
$action='file_manager';
clearstatcache(); clearstatcache();
} }
$action='file_manager';
}
// Remove directory // Remove directory
if ($action == 'confirm_deletesection' && GETPOST('confirm') == 'yes') if ($action == 'confirm_deletesection' && GETPOST('confirm') == 'yes')