diff --git a/src/middleware/persist.ts b/src/middleware/persist.ts index b56f531cde..fc8650034e 100644 --- a/src/middleware/persist.ts +++ b/src/middleware/persist.ts @@ -126,7 +126,10 @@ export interface PersistOptions { * A function to perform persisted state migration. * This function will be called when persisted state versions mismatch with the one specified here. */ - migrate?: (persistedState: unknown, version: number) => S | Promise + migrate?: ( + persistedState: unknown, + version: number, + ) => PersistedState | Promise /** * A function to perform custom hydration merges when combining the stored state with the current one. * By default, this function does a shallow merge.