MCPcopy Create free account
hub / github.com/MultiMC/Launcher / updateEntry

Method updateEntry

launcher/net/HttpMetaCache.cpp:118–134  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

116}
117
118bool HttpMetaCache::updateEntry(MetaEntryPtr stale_entry)
119{
120 if (!m_entries.contains(stale_entry->baseId))
121 {
122 qCritical() << "Cannot add entry with unknown base: "
123 << stale_entry->baseId.toLocal8Bit();
124 return false;
125 }
126 if (stale_entry->stale)
127 {
128 qCritical() << "Cannot add stale entry: " << stale_entry->getFullPath().toLocal8Bit();
129 return false;
130 }
131 m_entries[stale_entry->baseId].entry_list[stale_entry->relativePath] = stale_entry;
132 SaveEventually();
133 return true;
134}
135
136bool HttpMetaCache::evictEntry(MetaEntryPtr entry)
137{

Callers 1

finalizeCacheMethod · 0.80

Calls 2

getFullPathMethod · 0.80
containsMethod · 0.45

Tested by

no test coverage detected