stopped ajax from being asynchronous so we could check if the username is valid before we proceed