fixed user.friend count, and added js to Pages