Simplify condition, endsWith is clever enough.

wilder
David Faure 11 years ago
parent a76e5cc2e9
commit dd68b16110
  1. 3
      src/core/kdesktopfile.cpp

@ -101,8 +101,7 @@ QString KDesktopFile::locateLocal(const QString &path)
bool KDesktopFile::isDesktopFile(const QString &path)
{
return (path.length() > 8
&& path.endsWith(QLatin1String(".desktop")));
return path.endsWith(QLatin1String(".desktop"));
}
bool KDesktopFile::isAuthorizedDesktopFile(const QString &path)

Loading…
Cancel
Save