restful_authentication not working with <%= error_messages_for :user %>

I've got restful_authentication installed and working, but only if I remove <%= error_messages_for :user %> from the new.html.erb view in app/views/users/. I'm puzzled as to why this isn't working as I can't find anyone else having problems. I also have the following gems/ plugins installed:

gems

I found a <a href="textsnippets.com - This website is for sale! - textsnippets Resources and Information.; title="globalize error_messages_for on edge rails">post</a> on <a href="textsnippets.com - This website is for sale! - textsnippets Resources and Information.; title="TextSnippets">TextSnippets</a> by Claudio Poli that helped me out.