Fixed compatibility with Doctrine 2.4