Skip to content

Commit 78f6566

Browse files
author
Ruben van Leeuwen
committed
1719: Disables using previous form definition when data is loading
1 parent 487a561 commit 78f6566

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

frontend/packages/pydantic-forms/src/core/hooks/useApiProvider.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,9 @@ export function useApiProvider(
7575
revalidateIfStale: true,
7676
revalidateOnReconnect: false,
7777
revalidateOnFocus: false,
78-
keepPreviousData: true,
78+
// We want to make sure the correct data is showing so we don't want to prefill with stale data
79+
// we dont use the previous data because of that
80+
keepPreviousData: false,
7981
shouldRetryOnError: false,
8082

8183
...swrConfig,

0 commit comments

Comments
 (0)