1
0
mirror of https://github.com/tooot-app/app synced 2025-06-05 22:19:13 +02:00
This commit is contained in:
Zhiyuan Zheng
2021-01-12 00:12:44 +01:00
parent 284d6e46e0
commit 2df172d026
23 changed files with 311 additions and 227 deletions

View File

@ -381,7 +381,8 @@ const useTimelineMutation = ({
onSettled,
...(typeof onSuccess === 'function'
? { onSuccess }
: {
: onSuccess
? {
onSuccess: (data, params) => {
queryClient.cancelQueries(params.queryKey)
@ -397,7 +398,8 @@ const useTimelineMutation = ({
break
}
}
}),
}
: undefined),
...(onMutate && {
onMutate: params => {
queryClient.cancelQueries(params.queryKey)

View File

@ -11,7 +11,6 @@ const updateStatus = ({
}) => {
switch (payload.property) {
case 'poll':
console.log(payload.data)
if (reblog) {
item.reblog!.poll = payload.data
} else {