spacing & error handling fixes