Fix bug in filtering entities by project in the API