Patched getEntitiesByText