corrected error conditions due to some changes.