rudimentary error handling for login action