Fix compiler warning

No need to copy
This commit is contained in:
Aleix Pol 2020-08-14 16:50:08 +02:00
parent 61ab042d7a
commit 8de0f8223d

View file

@ -166,7 +166,7 @@ QVariant ExampleClientModel::data(const QModelIndex &index, int role) const
QString ExampleClientModel::longestCaption() const
{
QString caption;
for (const auto item : m_services) {
for (const auto &item : m_services) {
const QString name = item->name();
if (name.size() > caption.size()) {
caption = name;