We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0e51554 commit a8498f8Copy full SHA for a8498f8
src/shared/contexts/buckets.tsx
@@ -91,16 +91,18 @@ export const BucketProvider: FC<Props> = ({
91
92
// keep the redux store in sync
93
useEffect(() => {
94
- dispatch(
95
- setBuckets(
96
- RemoteDataState.Done,
97
- normalize<Bucket, BucketEntities, string[]>(
98
- buckets.filter(b => b.type !== 'sample'),
99
- arrayOfBuckets
+ if (loading === RemoteDataState.Done) {
+ dispatch(
+ setBuckets(
+ RemoteDataState.Done,
+ normalize<Bucket, BucketEntities, string[]>(
+ buckets.filter(b => b.type !== 'sample'),
100
+ arrayOfBuckets
101
+ )
102
)
103
- )
- }, [buckets])
104
+ }
105
+ }, [buckets, loading])
106
107
// TODO: load bucket creation limits on org change
108
// expose limits to frontend
0 commit comments