better error handling when password is not set