wcoast1973 (2) [Avatar] Offline
So far I have been following the book doing my own typing. I closed out iteration 6 with no real issues (despite the fact that I am on Rails 2.3.4). Now, just a few pages into iteration 7 I am stuck. After adding "to_xml_full" to the application controller (7.7), and making the change to the users controller (7.smilie, I get the error " when creating a duplicate user.

I've been through the changes to these two files with a fine tooth comb, then replaced my new text with the text from the Book Code. I continue to have the same issue. If I revert to ".to_xml" in the users controller (bypassing the new "to_xml_full" code in the application controller, I have no issues.

Any ideas would be greatly appreciated.

wcoast1973 (2) [Avatar] Offline
Re: to_xml_full errors in iteration 7
The solution is to cast msg to a string, so in Listing 7.7:
fullmsg = @base.class.human_attribute_name(attr) + " " + msg
needs to be
fullmsg = @base.class.human_attribute_name(attr) + " " + msg.to_s