Migrate local thread mutes (#4523)

* migrate thread mutes

* don't try and clear if not logged in yet

* migrate mutes one at a time

* write before mutating

* only migrate mutes of self posts

* use /** @deprecated */

* shouldLike -> shouldMute
This commit is contained in:
Samuel Newman 2024-06-18 22:05:59 +01:00 committed by GitHub
parent 502bcad701
commit 0012d1236f
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 58 additions and 4 deletions

View file

@ -304,8 +304,8 @@ export function useThreadMuteMutationQueue(
const queueToggle = useToggleMutationQueue<boolean>({
initialState: isThreadMuted,
runMutation: async (_prev, shouldLike) => {
if (shouldLike) {
runMutation: async (_prev, shouldMute) => {
if (shouldMute) {
await threadMuteMutation.mutateAsync({
uri: rootUri,
})