easily disable gedmo softdeletable

Gedmo softdeletable is a nice aid to not fully delete database entries, but set deletedAt. I used this for a Symfony2 project, but unfortunately in once instance I needed to temporarily disable this feature. There seems to be a nice little trick:

$em->setDeletedAt(new \DateTime());

Found it here

Leave a Reply

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.