converted alert messages into console.log so theres no interuption in submission