Fix "can't convert array into integer" in fetching users statistics.