update

updated according to changes and simplification of FlorianKoerner

Simplified "Ensuring the database persistence" example
https://github.com/symfony/symfony-docs/commit/f4306ac502d28bd1ee9bbc1b321f550f1f85429f