1
0
Fork 0

Removed unnecessary check for lower and upper folder

This commit is contained in:
Lukas Pioch 2017-03-16 17:07:50 +01:00
parent e0435f27bb
commit 4b1bc1cc5c
2 changed files with 1 additions and 7 deletions

View File

@ -68,7 +68,7 @@ void cPluginManager::RefreshPluginList(void)
AStringVector Folders;
for (auto & item: Contents)
{
if ((item == ".") || (item == "..") || (!cFile::IsFolder(PluginsPath + item)))
if (!cFile::IsFolder(PluginsPath + item))
{
// We only want folders, and don't want "." or ".."
continue;

View File

@ -336,12 +336,6 @@ bool cFile::DeleteFolderContents(const AString & a_FolderName)
auto Contents = cFile::GetFolderContents(a_FolderName);
for (const auto & item: Contents)
{
// Skip "." and ".." altogether:
if ((item == ".") || (item == ".."))
{
continue;
}
// Remove the item:
auto WholePath = a_FolderName + GetPathSeparator() + item;
if (IsFolder(WholePath))