Skip to content

Commit

Permalink
fix(query-core): use Math.round() on mutationId to get a non-decimal …
Browse files Browse the repository at this point in the history
…number
  • Loading branch information
ali-idrizi committed Nov 20, 2024
1 parent db9104b commit efbf935
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/query-core/src/mutationCache.ts
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ export class MutationCache extends Subscribable<MutationCacheListener> {
constructor(public config: MutationCacheConfig = {}) {
super()
this.#mutations = new Map()
this.#mutationId = performance.timeOrigin + performance.now()
this.#mutationId = Math.round(performance.timeOrigin + performance.now())
}

build<TData, TError, TVariables, TContext>(
Expand Down

0 comments on commit efbf935

Please sign in to comment.