@@ -361,7 +361,7 @@ function getSnippetRequest (url, method, style, hasParams, hasHeaders, contentTy
361361 filesInfo ) ;
362362 }
363363 if ( methodUC === 'POST' ) {
364- return getSnippetPostFormInOptions ( url , 'post' , hasParams , hasHeaders , requestTimeout , followRedirect ) ;
364+ return getSnippetPostFormInOptions ( url , style , hasParams , hasHeaders , requestTimeout , followRedirect ) ;
365365 }
366366 if ( methodUC === 'PUT' ) {
367367 return getSnippetPut ( url , hasParams , hasHeaders , requestTimeout , followRedirect ) ;
@@ -447,7 +447,7 @@ function convert (request, options, callback) {
447447 followRedirect = options . followRedirect ,
448448 ignoreWarnings = options . ignoreWarnings ,
449449 contentTypeHeaderValue = request . headers . get ( 'Content-Type' ) ,
450- url = getRequestURL ( request ) ,
450+ url = sanitizeString ( getRequestURL ( request ) ) ,
451451 snippetHeaders = getSnippetHeaders ( getRequestHeaders ( request ) , indentation ) ,
452452 snippetHeader = getSnippetHeader ( ignoreWarnings ) ,
453453 snippetFooter = getSnippetFooter ( ) ;
0 commit comments