]> git.immae.eu Git - github/wallabag/wallabag.git/blobdiff - src/Wallabag/ImportBundle/Import/WallabagImport.php
Clearing entities in the loop fail on Postgres
[github/wallabag/wallabag.git] / src / Wallabag / ImportBundle / Import / WallabagImport.php
index 9cd3dcb8bac7213118136503d64a799016de6cbb..581ec178f82e19ae530550568d9edf4f010ccab0 100644 (file)
@@ -172,15 +172,12 @@ abstract class WallabagImport extends AbstractImport
             // flush every 20 entries
             if (($i % 20) === 0) {
                 $this->em->flush();
-
-                // clear only affected entities
-                $this->em->clear(Entry::class);
-                $this->em->clear(Tag::class);
             }
             ++$i;
         }
 
         $this->em->flush();
+        $this->em->clear();
     }
 
     /**