add return in function createXMLHTTPRequest