It looks like this code was previously invalid for 1.8, where decode_www_form_component only takes a single argument.

I'm ok with putting the switch inside the method or outside.