summaryrefslogtreecommitdiffstats
path: root/src/core/file_sys/registered_cache.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/file_sys/registered_cache.cpp')
-rw-r--r--src/core/file_sys/registered_cache.cpp14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/core/file_sys/registered_cache.cpp b/src/core/file_sys/registered_cache.cpp
index 58917e094..3bb921210 100644
--- a/src/core/file_sys/registered_cache.cpp
+++ b/src/core/file_sys/registered_cache.cpp
@@ -645,6 +645,20 @@ ContentProviderUnion::ListEntriesFilterOrigin(std::optional<ContentProviderUnion
return out;
}
+std::optional<ContentProviderUnionSlot> ContentProviderUnion::GetSlotForEntry(
+ u64 title_id, ContentRecordType type) const {
+ for (const auto& [slot, provider] : providers) {
+ if (provider == nullptr)
+ continue;
+
+ if (provider->HasEntry(title_id, type)) {
+ return slot;
+ }
+ }
+
+ return std::nullopt;
+}
+
ManualContentProvider::~ManualContentProvider() = default;
void ManualContentProvider::AddEntry(TitleType title_type, ContentRecordType content_type,