Response Header write operation was missing from the previous code so the client would never get the content if left that way