fixed doctrine array_diff to work with php 5.4+