Fixed bugs with friends list

Fixed some SQL and also fixed the bug with only being able to add one
friend at a time.