patch class.rb