[client] Simplify building error messages