src/Service/EntityManager/ReductionManager.php
/**
     * Enable/Disable a Reduction and do not include an Image during the flush.
     */
Enable/Disable a Reduction and do not include an Image during the flush.
Enable / Disable a Reduction and do not include an Image during the flush .
public function changeStatus(Reduction $reduction): Reduction
    {
        $reduction->isActive() ? $reduction->setIsActive(false) : $reduction->setIsActive(true);
        if ($reduction->getImage()) {
            $reduction->setImageOutOfContext();
        }
        return $reduction;
    }
public function changeStatus ( Reduction $ reduction ) : Reduction { $ reduction -> isActive ( ) ? $ reduction -> setIsActive ( false ) : $ reduction -> setIsActive ( true ) ; if ( $ reduction -> getImage ( ) ) { $ reduction -> setImageOutOfContext ( ) ; } return $ reduction ; }
Enable/Disable a Reduction and do not include an Image during the flush.
Enable / Disable a Reduction and do not include an Image during the flush .