I have a problem in my code . This is part of it:
function checkIfAvailable(username){ var url = \"/checkAvail?user=\"+username; var ans = $.ajax({ url
Message inside console.log("-1-1-1-1 WE GOT 404!") is same for both 404 and 200. change the message for 200 like console.log("Success.....")