aboutsummaryrefslogtreecommitdiffstats
path: root/src/modules/addon/AddonFunctions.cpp
diff options
context:
space:
mode:
authorGravatar Alexey Sokolov2016-04-30 18:48:40 +0100
committerGravatar Alexey Sokolov2016-04-30 18:50:45 +0100
commit97ecdf6a1b7f95bc1b342b3eaf141cd460249680 (patch)
treedfa139170f95eeda51f241580cc019ab0f4684d8 /src/modules/addon/AddonFunctions.cpp
parentApply clang-tidy: modernize-use-default (diff)
downloadKVIrc-97ecdf6a1b7f95bc1b342b3eaf141cd460249680.tar.gz
KVIrc-97ecdf6a1b7f95bc1b342b3eaf141cd460249680.tar.bz2
KVIrc-97ecdf6a1b7f95bc1b342b3eaf141cd460249680.zip
Apply clang-tidy: modernize-loop-convert
Diffstat (limited to 'src/modules/addon/AddonFunctions.cpp')
-rw-r--r--src/modules/addon/AddonFunctions.cpp8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/modules/addon/AddonFunctions.cpp b/src/modules/addon/AddonFunctions.cpp
index 88a7b0fdd..5ffd5466c 100644
--- a/src/modules/addon/AddonFunctions.cpp
+++ b/src/modules/addon/AddonFunctions.cpp
@@ -91,9 +91,9 @@ namespace AddonFunctions
return notAValidAddonPackage(szError);
// make sure the default fields exist
- for(int i = 0; i < 6; i++)
+ for(auto & check_field : check_fields)
{
- pValue = pInfoFields->find(check_fields[i]);
+ pValue = pInfoFields->find(check_field);
if(!pValue)
return notAValidAddonPackage(szError);
}
@@ -340,10 +340,8 @@ namespace AddonFunctions
return false;
}
- for(QFileInfoList::Iterator it = ls.begin(); it != ls.end(); ++it)
+ for(auto & inf : ls)
{
- const QFileInfo & inf = *it;
-
if(inf.isDir())
{
if(!pw.addDirectory(inf.absoluteFilePath(), QString("%1/").arg(inf.fileName())))