Using singleton in chat window