Skip to content

Commit

Permalink
Merge pull request #266 from Synthetixio/staging
Browse files Browse the repository at this point in the history
Release
  • Loading branch information
jmzwar authored Jan 2, 2024
2 parents 836c728 + 4bdfe56 commit c8db8c5
Show file tree
Hide file tree
Showing 6 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion pages/api/delegation.ts
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ export default async function handler(
}

const result = await fetchDuneData();
cache.set(cacheKey, result, 3600);
cache.set(cacheKey, result, 10800); // Refresh cache every 3 hours
res.status(200).json({ result });
} catch (err) {
res.status(500).json({ error: 'failed to load data' });
Expand Down
2 changes: 1 addition & 1 deletion pages/api/integrator.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ export default async function handler(
}

const result = await fetchDuneData();
cache.set(cacheKey, result, 3600);
cache.set(cacheKey, result, 10800); // Refresh cache every 3 hours
res.status(200).json({ result });
} catch (err) {
res.status(500).json({ error: 'failed to load data' });
Expand Down
2 changes: 1 addition & 1 deletion pages/api/interest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ export default async function handler(
}

const result = await fetchDuneData();
cache.set(cacheKey, result, 3600);
cache.set(cacheKey, result, 10800); // Refresh cache every 3 hours
res.status(200).json({ result });
} catch (err) {
res.status(500).json({ error: 'failed to load data' });
Expand Down
2 changes: 1 addition & 1 deletion pages/api/mintburn.ts
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ export default async function handler(
}

const result = await fetchDuneData();
cache.set(cacheKey, result, 3600);
cache.set(cacheKey, result, 10800); // Refresh cache every 3 hours
res.status(200).json({ result });
} catch (err) {
res.status(500).json({ error: 'failed to load data' });
Expand Down
2 changes: 1 addition & 1 deletion pages/api/pnl.ts
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ export default async function handler(
}

const result = await fetchDuneData();
cache.set(cacheKey, result, 3600);
cache.set(cacheKey, result, 10800); // Refresh cache every 3 hours
res.status(200).json({ result });
} catch (err) {
res.status(500).json({ error: 'failed to load data' });
Expand Down
2 changes: 1 addition & 1 deletion pages/api/tvl.ts
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ export default async function handler(
}

const result = await fetchDuneData();
cache.set(cacheKey, result, 3600);
cache.set(cacheKey, result, 10800); // Refresh cache every 3 hours
res.status(200).json({ result });
} catch (err) {
res.status(500).json({ error: 'failed to load data' });
Expand Down

1 comment on commit c8db8c5

@vercel
Copy link

@vercel vercel bot commented on c8db8c5 Jan 2, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.