Fix bug https://github.com/sonata-project/SonataMediaBundle/issues/430