added better error message