This snippet wasn't particularly helpful as `add_error()` is described in greater details in the following section. Thanks Claude Paroz for the report.