Forum: Ruby on Rails 0 errors prohibited this model from being saved

Announcement (2017-05-07): is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see and for other Rails- und Ruby-related community platforms.
tansaku (Guest)
on 2008-11-05 18:40
(Received via mailing list)

I just generated a scaffold for some existing models I have, and
everything is working fine, except I get a 0 error message on the edit

0 errors prohibited this statistic type from being saved

There were problems with the following fields:

I would have thought the default behaviour would be to hide this error
message if there are no errors, and that is my impression of what
happened when I have scaffolded from scratch before.

I am using Rails 2.1.1 and the edit view looks like this:

<% form_for(@statistic_type) do |f| %>
  <%= f.error_messages %>
    <b>Name</b><br />
    <%= f.text_field :name %>


Has anybody every encountered this before?

It's not a huge immediate problem as all the functionality seems to be
working, it's just that it will be confusing for users ...

Many thanks in advance
This topic is locked and can not be replied to.