Skip to content

Commit 6422dc3

Browse files
authored
Merge branch 'main' into main
2 parents 71ba3eb + 89af093 commit 6422dc3

File tree

4 files changed

+14
-8
lines changed

4 files changed

+14
-8
lines changed

.changeset/lucky-lamps-repair.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'@clerk/clerk-js': patch
3+
---
4+
5+
Fix useFetch to update fetcher ref

.github/workflows/release-canary.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ jobs:
3434
turbo-team: ${{ vars.TURBO_TEAM }}
3535
turbo-token: ${{ secrets.TURBO_TOKEN }}
3636
playwright-enabled: true # Must be present to enable caching on branched workflows
37-
registry-url: 'https://registry.npmjs.org'
37+
registry-url: "https://registry.npmjs.org"
3838

3939
- name: Version packages for canary
4040
id: version-packages
@@ -65,9 +65,9 @@ jobs:
6565
github.rest.actions.createWorkflowDispatch({
6666
owner: 'clerk',
6767
repo: 'sdk-infra-workers',
68-
workflow_id: 'update-clerkjs.yml',
68+
workflow_id: 'update-pkg-versions.yml',
6969
ref: 'main',
70-
inputs: { version: clerkjsVersion }
70+
inputs: { clerkjsVersion: clerkjsVersion }
7171
})
7272
7373
if (nextjsVersion.includes('canary')) {

.github/workflows/release.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -55,8 +55,8 @@ jobs:
5555
id: changesets
5656
uses: changesets/action@v1
5757
with:
58-
commit: 'ci(repo): Version packages'
59-
title: 'ci(repo): Version packages'
58+
commit: "ci(repo): Version packages"
59+
title: "ci(repo): Version packages"
6060
publish: pnpm release
6161
# Workaround for https://github.com/changesets/changesets/issues/421
6262
version: pnpm version-packages
@@ -83,7 +83,7 @@ jobs:
8383
github.rest.actions.createWorkflowDispatch({
8484
owner: 'clerk',
8585
repo: 'sdk-infra-workers',
86-
workflow_id: 'update-clerkjs.yml',
86+
workflow_id: 'update-pkg-versions.yml',
8787
ref: 'main',
8888
inputs: { version: clerkjsVersion }
8989
})
@@ -145,5 +145,5 @@ jobs:
145145
uses: ./.github/actions/init
146146
with:
147147
node-version: ${{ matrix.version }}
148-
turbo-team: ''
149-
turbo-token: ''
148+
turbo-team: ""
149+
turbo-token: ""

packages/clerk-js/src/ui/hooks/useFetch.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -130,6 +130,7 @@ export const useFetch = <K, T>(
130130
}, [setCache, setRevalidationCounter]);
131131

132132
useEffect(() => {
133+
fetcherRef.current = fetcher;
133134
const fetcherMissing = !fetcherRef.current;
134135
const isCacheStale =
135136
typeof getCache()?.cachedAt === 'undefined' ? true : Date.now() - (getCache()?.cachedAt || 0) >= staleTime;

0 commit comments

Comments
 (0)