when room is requested, server's response includes status code. Angular .get accordingly calls success or error method