fix to http method detection