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-02-13 00:15:42 +01:00
parent 6b58bf24e4
commit d2aec8d590
3 changed files with 56 additions and 33 deletions

View File

@ -379,7 +379,7 @@ const useTimelineMutation = ({
? { onSuccess }
: onSuccess
? {
onSuccess: (data, params) => {
onSuccess: ({ body }, params) => {
queryClient.cancelQueries(params.queryKey)
haptics('Success')
@ -387,7 +387,7 @@ const useTimelineMutation = ({
case 'updateStatusProperty':
switch (params.payload.property) {
case 'poll':
params.payload.data = (data as unknown) as Mastodon.Poll
params.payload.data = (body as unknown) as Mastodon.Poll
updateStatusProperty({ queryClient, ...params })
break
}