Fixed a bug in trending response (which was overwriting entries with the
same number). Finished stats page. Need to move it to admin priv.