]> Raphaƫl G. Git Repositories - airbundle/blobdiff - Entity/Snippet.php
Fix header comment
[airbundle] / Entity / Snippet.php
index a764a6602586c3c121476d77a266f7d41bbc3f8a..fa5fe996fbcc68d74fc4ccf6d7dec693aaeef29a 100644 (file)
@@ -432,7 +432,7 @@ class Snippet {
         */
        public function preUpdate(PreUpdateEventArgs $eventArgs) {
                //Check that we have an snippet instance
         */
        public function preUpdate(PreUpdateEventArgs $eventArgs) {
                //Check that we have an snippet instance
-               if (($snippet = $eventArgs->getEntity()) instanceof Snippet) {
+               if (($snippet = $eventArgs->getObject()) instanceof Snippet) {
                        //Set updated value
                        $snippet->setUpdated(new \DateTime('now'));
                }
                        //Set updated value
                        $snippet->setUpdated(new \DateTime('now'));
                }