I can get alert to pop up but I still get else statement in console.