wasm: do not revise url of queries
I think this may have been for some POST method form queries, but obviously was missing something. Task-number: QTBUG-72382 Change-Id: I59016776aeedf4b5599b3b44af70610babb0a61e Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io> Reviewed-by: Ryan Chu <ryan.chu@qt.io>
This commit is contained in:
parent
582237a593
commit
87b20009cc
@ -315,17 +315,9 @@ void QNetworkReplyWasmImplPrivate::doSendRequest()
|
||||
val xhr = val::global("XMLHttpRequest").new_();
|
||||
std::string verb = q->methodName().toStdString();
|
||||
|
||||
QUrl url;
|
||||
QString extraDataString;
|
||||
|
||||
if (request.url().hasQuery()) { //strip query from url
|
||||
extraDataString = request.url().query(QUrl::FullyEncoded);
|
||||
QString urlStr = request.url().toString();
|
||||
url.setUrl(urlStr.left(urlStr.indexOf("?")));
|
||||
} else {
|
||||
url = request.url();
|
||||
}
|
||||
xhr.call<void>("open", verb, url.toString().toStdString());
|
||||
xhr.call<void>("open", verb, request.url().toString().toStdString());
|
||||
|
||||
xhr.set("onerror", val::module_property("QNetworkReplyWasmImplPrivate_requestErrorCallback"));
|
||||
xhr.set("onload", val::module_property("QNetworkReplyWasmImplPrivate_loadCallback"));
|
||||
|
Loading…
Reference in New Issue
Block a user