Draft and resiliated member could (re)validate

This commit is contained in:
daraelmin 2021-04-27 02:36:47 +02:00 committed by GitHub
parent 25e3beb3ee
commit db92de2a22
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -394,7 +394,7 @@ if ($ispaymentok) {
// Do action only if $FinalPaymentAmt is set (session variable is cleaned after this page to avoid duplicate actions when page is POST a second time)
if (!empty($FinalPaymentAmt) && $paymentTypeId > 0) {
$result = $object->status == $object::STATUS_RESILIATE ? -1 : $object->validate($user); // if membre is excluded (status == -2) the new validation is not possible
$result = $object->status < $object::STATUS_DRAFT ? -1 : $object->validate($user); // if membre is excluded (status == -2) the new validation is not possible
if ($result < 0 || empty($object->datevalid)) {
$error++;
$errmsg = $object->error;