Apply suggestions from code review

Co-authored-by: Sefa Eyeoglu <contact@scrumplex.net>
Signed-off-by: Rachel Powers <508861+Ryex@users.noreply.github.com>
This commit is contained in:
Rachel Powers
2023-01-13 13:11:20 -07:00
parent 574af2c795
commit f7b0ba88da
2 changed files with 4 additions and 5 deletions

View File

@ -1816,7 +1816,7 @@ void MainWindow::processURLs(QList<QUrl> urls)
{
// NOTE: This loop only processes one dropped file!
for (auto& url : urls) {
qDebug() << "Processing :" << url;
qDebug() << "Processing" << url;
// The isLocalFile() check below doesn't work as intended without an explicit scheme.
if (url.scheme().isEmpty())
@ -1832,9 +1832,7 @@ void MainWindow::processURLs(QList<QUrl> urls)
auto type = ResourceUtils::identify(localFileInfo);
// bool is_resource = type;
if (!(ResourceUtils::ValidResourceTypes.count(type) > 0)) { // probably instance/modpack
if (ResourceUtils::ValidResourceTypes.count(type) == 0) { // probably instance/modpack
addInstance(localFileName);
continue;
}