Bug Fix on Stats Page

Fixed a bug which was causing the wrong results to be displayed.