Refactored Errors to reduce footprint