Description
Feedback messages are Serializables. While I personally don't agree with that (since users want to see a String, not a Serializable object), it is the way it is. However, that means we should be careful that the feedback message object is handled the same way everywhere.
For instance, FeedbackPanel.newMessageDisplayComponent(String, FeedbackMessage) does a toString() on it, while AjaxEditableLabel.onError(AjaxRequestTarget) casts it to String if it's a String and pretends it's not there if it's not.
Presumably, the latter is not the intended way of using the message, and it should be corrected to act like the former.
I believe it raises the issue of danger with using the wrong type of object very well, though. It opens the road for bugs like this one, where your feedback message that isn't a message isn't handled properly because the framework assumes it's a message. IMO, we should make it a String and the user should put whatever their toString would generate in a feedback message, instead of the object itself. KISS.