Add error message instead of trigger_error