Store Person images in person cache and move client cache args to "dataSourceOptions" instead of queryOptions

This commit is contained in:
HighImKevin
2026-09-28 01:25:00 -04:00
parent 6b51d57f95
commit 5ae1e66b87
9 changed files with 109 additions and 35 deletions
+14 -3
View File
@@ -273,7 +273,12 @@
let queryResult;
if (query.dataSource) {
queryResult = await ApiHelper.fetchFromDataSource(query.dataSource, query.queryOptions || {});
queryResult = await ApiHelper.fetchFromDataSource(
query.dataSource,
query.queryOptions || {},
true,
query.dataSourceOptions
);
} else {
const queryUrl = ApiHelper.buildQueryFromSection(query, userId, serverUrl, sectionConfig.renderMode === 'Spotlight', { sectionType: sectionConfig.type });
@@ -575,7 +580,8 @@
: 'getTopActors';
return {
dataSource: `PeopleCache.${method}`,
queryOptions: { ItemType: itemType, Limit: 100 }
dataSourceOptions: { ItemType: itemType },
queryOptions: { Limit: 100 }
};
}
if (discoveryType === 'Similar' || discoveryType === 'Watchlist') {
@@ -676,7 +682,12 @@
const built = ApiHelper.buildQueryFromSection(sourceQuery, userId, serverUrl, false);
if (typeof built === 'object' && built.dataSource) {
const result = await ApiHelper.fetchFromDataSource(built.dataSource, built.options || {}, false);
const result = await ApiHelper.fetchFromDataSource(
built.dataSource,
built.options || {},
false,
built.dataSourceOptions
);
return unwrapQueryItems(result);
}