mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-03-22 23:05:36 +08:00
Fix VS IDE warning/tip
No need to return value from CUrl::appendQuery.
This commit is contained in:
@@ -95,19 +95,18 @@ namespace BlackMisc
|
||||
return !m_query.isEmpty();
|
||||
}
|
||||
|
||||
QString CUrl::appendQuery(const QString &queryToAppend)
|
||||
void CUrl::appendQuery(const QString &queryToAppend)
|
||||
{
|
||||
if (queryToAppend.isEmpty()) { return m_query; }
|
||||
if (queryToAppend.isEmpty()) { return; }
|
||||
const QString q(stripQueryString(queryToAppend));
|
||||
if (q.isEmpty()) { return m_query; }
|
||||
if (q.isEmpty()) { return; }
|
||||
m_query += hasQuery() ? "&" + q : q;
|
||||
return m_query;
|
||||
}
|
||||
|
||||
QString CUrl::appendQuery(const QString &key, const QString &value)
|
||||
void CUrl::appendQuery(const QString &key, const QString &value)
|
||||
{
|
||||
if (key.isEmpty()) { return m_query; }
|
||||
return this->appendQuery(key + "=" + value);
|
||||
if (key.isEmpty()) { return; }
|
||||
this->appendQuery(key + "=" + value);
|
||||
}
|
||||
|
||||
QString CUrl::getFullUrl(bool withQuery) const
|
||||
|
||||
@@ -106,10 +106,10 @@ namespace BlackMisc
|
||||
bool hasQuery() const;
|
||||
|
||||
//! Append query
|
||||
QString appendQuery(const QString &queryToAppend);
|
||||
void appendQuery(const QString &queryToAppend);
|
||||
|
||||
//! Append query
|
||||
QString appendQuery(const QString &key, const QString &value);
|
||||
void appendQuery(const QString &key, const QString &value);
|
||||
|
||||
//! Empty
|
||||
bool isEmpty() const;
|
||||
|
||||
Reference in New Issue
Block a user