!trivial: define and call class methods in From appropriate

This commit is contained in:
Álvaro Gil 2010-04-05 11:07:35 -03:00
parent fa881a88c8
commit 15102bd60d

View File

@ -51,11 +51,11 @@ module Webrat
query_string << field.to_query_string query_string << field.to_query_string
end end
query_params = Form.query_string_to_params(query_string.join('&')) query_params = self.class.query_string_to_params(query_string.join('&'))
query_params = Form.replace_params_values(query_params, replaces) query_params = self.class.replace_params_values(query_params, replaces)
Form.unescape_params(query_params) self.class.unescape_params(query_params)
end end
def form_method def form_method
@ -66,8 +66,6 @@ module Webrat
@element["action"].blank? ? @session.current_url : @element["action"] @element["action"].blank? ? @session.current_url : @element["action"]
end end
protected
def self.replace_param_value(params, oval, nval) def self.replace_param_value(params, oval, nval)
output = Hash.new output = Hash.new
params.each do |key, value| params.each do |key, value|