Skip to content

Commit

Permalink
covered a case when there are not a single <item>; also prefer <fervo…
Browse files Browse the repository at this point in the history
…r:version> over <sparkle:version>
  • Loading branch information
pypt committed Jan 28, 2013
1 parent 70d9926 commit f4e20fb
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions fvupdater.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -409,17 +409,13 @@ bool FvUpdater::xmlParseFeed()
if (! candidateVersion.isEmpty()) {
xmlEnclosureVersion = candidateVersion;
}
} else {
xmlEnclosureVersion = "";
}
if (attribs.hasAttribute("fervor:version")) {
QString candidateVersion = attribs.value("fervor:version").toString().trimmed();
if (! candidateVersion.isEmpty()) {
xmlEnclosureVersion = candidateVersion;
}
} else {
xmlEnclosureVersion = "";
}
}

if (attribs.hasAttribute("length")) {
xmlEnclosureLength = attribs.value("length").toString().toLong();
Expand Down Expand Up @@ -484,6 +480,10 @@ bool FvUpdater::xmlParseFeed()
}
}

// No updates were found if we're at this point
// (not a single <item> element found)
showInformationDialog(tr("No updates were found."), false);

return false;
}

Expand Down

0 comments on commit f4e20fb

Please sign in to comment.