MCPcopy Create free account
hub / github.com/cortexkit/magic-context / checkForUpdate

Function checkForUpdate

packages/dashboard/src/lib/updater.ts:9–21  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

7 * Used by the background polling in App.tsx for the toast notification.
8 */
9export async function checkForUpdate(): Promise<string | null> {
10 if (!isTauri()) return null;
11 try {
12 const update = await checkTauriUpdate();
13 if (update) {
14 cachedUpdate = update;
15 return update.version;
16 }
17 } catch {
18 // Silent failure for background checks
19 }
20 return null;
21}
22
23/**
24 * Download and install the cached update, then relaunch.

Callers 1

pollFunction · 0.90

Calls 2

isTauriFunction · 0.90
checkTauriUpdateFunction · 0.90

Tested by

no test coverage detected