if (ref $errors) {
# pass errors to template
$r->template_args->{errors} = $errors;
- foreach my $error (keys %$errors) {
- $r->template_args->{errors}{ucfirst($error)} = $errors->{$error}
- }
-
# Set it up as it was:
$r->template_args->{cgi_params} = $r->params;
$r->template("edit");