QUrl::setEncodedQueryItems should replace
If there is already a query string present in the url. It should be replace when setEncodedQueryItems is called again. Task-number: QTBUG-26148 Change-Id: I2bd4e1f5d9b4161d64556062e97141888ad89b3b Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
This commit is contained in:
parent
c752bb8eb8
commit
79b14f42ba
@ -145,7 +145,7 @@ inline void QUrl::removeAllEncodedQueryItems(const QByteArray &key)
|
||||
|
||||
inline void QUrl::setEncodedQueryItems(const QList<QPair<QByteArray, QByteArray> > &qry)
|
||||
{
|
||||
QUrlQuery q(*this);
|
||||
QUrlQuery q;
|
||||
QList<QPair<QByteArray, QByteArray> >::ConstIterator it = qry.constBegin();
|
||||
for ( ; it != qry.constEnd(); ++it)
|
||||
q.addQueryItem(QString::fromUtf8(it->first), QString::fromUtf8(it->second));
|
||||
|
Loading…
Reference in New Issue
Block a user