Fixes styling and error processing logic.