Catching NoMethodError is really strange. What is reason here? In ruby you can dynamically introspect object to get his methods.