propelorm/Propel2

View on GitHub
src/Propel/Generator/Behavior/Archivable/templates/objectPreDelete.php
A

No issues here. Congrats!

<?php if ($isAddHooks) : ?>
if ($ret) {
    if ($this->archiveOnDelete) {
        // do nothing yet. The object will be archived later when calling <?php echo $queryClassName ?>::delete().
    } else {
        $deleteQuery->setArchiveOnDelete(false);
        $this->archiveOnDelete = true;
    }
}
<?php else: ?>
if ($this->archiveOnDelete) {
    // do nothing yet. The object will be archived later when calling <?php echo $queryClassName ?>::delete().
} else {
    $deleteQuery->setArchiveOnDelete(false);
    $this->archiveOnDelete = true;
}
<?php endif;

Size

Lines of code
15