add min version to product updates

This commit is contained in:
miloschwartz
2025-12-22 15:28:44 -05:00
parent 4da0a752ef
commit c362bc673c
2 changed files with 11 additions and 7 deletions

View File

@@ -41,12 +41,13 @@ export type LatestVersionResponse = {
};
export const productUpdatesQueries = {
list: (enabled: boolean) =>
list: (enabled: boolean, version?: string) =>
queryOptions({
queryKey: ["PRODUCT_UPDATES"] as const,
queryFn: async ({ signal }) => {
const sp = new URLSearchParams({
build
build,
...(version ? { version } : {})
});
const data = await remote.get<ResponseT<ProductUpdate[]>>(
`/product-updates?${sp.toString()}`,