1st set of error fixes