mirror of
https://github.com/fosrl/pangolin.git
synced 2026-03-10 12:46:37 +00:00
Remove warning for limit
This commit is contained in:
@@ -105,6 +105,7 @@ async function query(query: Q) {
|
|||||||
// throw an error
|
// throw an error
|
||||||
throw createHttpError(
|
throw createHttpError(
|
||||||
HttpCode.BAD_REQUEST,
|
HttpCode.BAD_REQUEST,
|
||||||
|
// todo: is this even possible?
|
||||||
`Too many distinct countries. Please narrow your query.`
|
`Too many distinct countries. Please narrow your query.`
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -219,15 +219,17 @@ async function queryUniqueFilterAttributes(
|
|||||||
.limit(DISTINCT_LIMIT+1)
|
.limit(DISTINCT_LIMIT+1)
|
||||||
]);
|
]);
|
||||||
|
|
||||||
if (
|
// TODO: for stuff like the paths this is too restrictive so lets just show some of the paths and the user needs to
|
||||||
uniqueActors.length > DISTINCT_LIMIT ||
|
// refine the time range to see what they need to see
|
||||||
uniqueLocations.length > DISTINCT_LIMIT ||
|
// if (
|
||||||
uniqueHosts.length > DISTINCT_LIMIT ||
|
// uniqueActors.length > DISTINCT_LIMIT ||
|
||||||
uniquePaths.length > DISTINCT_LIMIT ||
|
// uniqueLocations.length > DISTINCT_LIMIT ||
|
||||||
uniqueResources.length > DISTINCT_LIMIT
|
// uniqueHosts.length > DISTINCT_LIMIT ||
|
||||||
) {
|
// uniquePaths.length > DISTINCT_LIMIT ||
|
||||||
throw new Error("Too many distinct filter attributes to retrieve. Please refine your time range.");
|
// uniqueResources.length > DISTINCT_LIMIT
|
||||||
}
|
// ) {
|
||||||
|
// throw new Error("Too many distinct filter attributes to retrieve. Please refine your time range.");
|
||||||
|
// }
|
||||||
|
|
||||||
return {
|
return {
|
||||||
actors: uniqueActors
|
actors: uniqueActors
|
||||||
|
|||||||
Reference in New Issue
Block a user