simplified the error methods a bit