Closed shawnzam closed 3 months ago
I'm not entirely sure how django behaves when providing a keyword argument to an URL which does not take said argument. We would have to make sure that this is backwards compatible.
Judging from here and here, you should be able to pair inviter/invitees before the redirect is returned by defining a signal handler that connects to invitations.signals.invite_accepted
:
@receiver(invite_accepted, sender=Invitation)
def handle_invite_accepted(sender, email, request, invitation):
inviter = invitation.inviter
invitee = request.user
...
@shawnzam Does this work for you?
Thanks for this contribution. I'm not sure if other people will find it helpful, especially given the workaround given by @blag. I'm closing this pull request to avoid it stagnating.
Allow the Invitation key to passed to the redirected for further inspection. This is used to implement a pairing model in my case.