MCPcopy Create free account
hub / github.com/FreesmTeam/FreesmLauncher / getLatestForParent

Method getLatestForParent

launcher/meta/VersionList.cpp:305–318  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

303}
304
305Version::Ptr VersionList::getLatestForParent(const QString& uid, const QString& version)
306{
307 Version::Ptr latestCompat = nullptr;
308 for (auto ver : m_versions) {
309 auto& reqs = ver->requiredSet();
310 auto parentReq = std::find_if(reqs.begin(), reqs.end(), [uid, version](const Require& req) -> bool {
311 return req.uid == uid && req.equalsVersion == version;
312 });
313 if (parentReq != reqs.end()) {
314 latestCompat = getBetterVersion(latestCompat, ver);
315 }
316 }
317 return latestCompat;
318}
319
320} // namespace Meta

Callers 1

performUpdateActionsMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected