friend chats correctly adds to database and checks if already exists in database