added chat functionality using firebase