attempting to get rid of errors, fixing exceptions