Skip user details step for logged in users (#602)

This commit is contained in:
Luke Vella 2023-03-23 12:17:56 +00:00 committed by GitHub
parent f858bcc5f4
commit d8e3dcd357
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
41 changed files with 548 additions and 636 deletions

View file

@ -42,15 +42,8 @@ const Discussion: React.FunctionComponent = () => {
const posthog = usePostHog();
const addComment = trpc.polls.comments.add.useMutation({
onSuccess: (newComment) => {
onSuccess: () => {
posthog?.capture("created comment");
queryClient.polls.comments.list.setData(
{ pollId },
(existingComments = []) => {
return [...existingComments, newComment];
},
);
},
});