Every line of 'ajax content type' code snippets is scanned for vulnerabilities by our powerful machine learning engine that combs millions of open source libraries, ensuring your JavaScript code is secure.
111 function getResponseType(contentType) { 112 if (contentType === undefined) { 113 return null; 114 } 115 116 if (contentType.indexOf('xml') !== -1) { 117 return 'xml'; 118 } 119 120 if (contentType.indexOf('html') !== -1) { 121 return 'html'; 122 } 123 124 return contentType; 125 }