Skip folders when updating mods.

Previously the mod updater would fail, reporting "The mod updater was aborted!", when trying to update a folder.

Signed-off-by: bolli24 <4827765-bolli24@users.noreply.gitlab.com>
This commit is contained in:
bolli24 2023-09-22 21:10:27 +02:00
parent 98bc102f5b
commit f3c089792a

View File

@ -236,6 +236,11 @@ auto ModUpdateDialog::ensureMetadata() -> bool
if (skip_rest) if (skip_rest)
continue; continue;
if (candidate->type() == ResourceType::FOLDER) {
m_failed_metadata.append({ candidate, tr("This is a folder.") });
continue;
}
if (confirm_rest) { if (confirm_rest) {
addToTmp(candidate, provider_rest); addToTmp(candidate, provider_rest);
should_try_others.insert(candidate->internal_id(), try_others_rest); should_try_others.insert(candidate->internal_id(), try_others_rest);