Disable fetch cache to sync history across computers

This commit is contained in:
Christian Vidal Wolf
2026-04-10 19:45:05 +02:00
parent 61daf8083f
commit 1c72eae60a
+2
View File
@@ -13,6 +13,7 @@ export async function getAllSyncedRows(token?: string): Promise<Record<string, S
const response = await fetch(
`${SUPABASE_URL}/rest/v1/products?select=product_id,data,status&order=updated_at.desc`,
{
cache: 'no-store',
headers: {
'apikey': SUPABASE_KEY,
'Authorization': `Bearer ${token || SUPABASE_KEY}`
@@ -129,6 +130,7 @@ export async function getHistory(token?: string): Promise<HistoryEntry[]> {
const response = await fetch(
`${SUPABASE_URL}/rest/v1/products_history?select=*&order=changed_at.desc&limit=100`,
{
cache: 'no-store',
headers: {
'apikey': SUPABASE_KEY,
'Authorization': `Bearer ${token || SUPABASE_KEY}`