Refactored errors