implemented login validation with alert error prompting