Refactor.

Avoid a useless intermediate collection.