Add collection() to global functions
Merge pull request #1860 from bcrowe/3.0-collection

3.0 - Add collection() to global functions