13 Oct
2009
13 Oct
'09
11:53
* J.Daniel Schmidt
+++ b/plugins/registration/app/views/registration/create.html.erb @@ -0,0 +1,11 @@ +<%= # @registration == nil ? "@registration is nil - FIXME" : @registration.to_xml + -%> +<%= case @registration.class.to_s + when 'NilClass' + "@registration is nil" + when 'String' + @registration.to_s + when 'Registration' + @registration.to_xml + end
There's no need to convert the class to a string. Do a simple case @registration and match for classes in the 'when'. Klaus --- SUSE LINUX Products GmbH, GF: Markus Rex, HRB 16746 (AG Nürnberg) -- To unsubscribe, e-mail: yast-devel+unsubscribe@opensuse.org For additional commands, e-mail: yast-devel+help@opensuse.org