Update collectionapi.js

soz for cluttering the repo, just don't know how to do it otherwise with my setup.