implmemented writing to firebase