added exception for a wrong path