Added a server-side collection for statistics, and fixed some routes