module Rack::Request::Helpers
def delete_param(k)
If the parameter is in both GET and POST, the POST value takes precedence since that's how #params works.
Destructively delete a parameter, whether it's in GET or POST. Returns the value of the deleted parameter.
def delete_param(k) post_value, get_value = self.POST.delete(k), self.GET.delete(k) post_value || get_value end