When a party invitation is sent, a user with that option enabled gets an email. If the user is removed from the party, there's an email for that as well. There is, however, no email sent for if the invitation is rescinded before you join -- making it possible to get an email and sign in to accept, but find nothing.
This email should probably not be exactly the same as the removed from party email (it was the same in APIv2), but it should exist.
I think this is good idea.
@lemoness If you'd like this, would you like to provide words for the email?
Yes, this makes sense. Perhaps it should have the same subject line so that it could thread?
As for the body of the email, let's do:
"Your Party invitation has been rescinded by the party leader, so your invitation link will no longer work. To find a different Party, try posting in the Party Wanted Guild. Good luck!"
To the Blacksmith who works on this: you won't be able to test sending the email from your local install. We'll test it after you've submitted a PR.
Note Lemoness's comment about the subject being the same as for the invitation email - that's a good point.
I can look into doing this.
So from what I'm seeing, it looks like the only time habitica tries to send an email on having someone removed from a group (whether invited or not) is when someone has passed a long an optional message when they removed the person. So the current expected behavior is no email either when removing someone or rescinding an invite unless a message has been provided. Do we want to send an email by default in both cases?
In addition, during my testing, it looks like this functionality wasn't working. In the new API, it was trying to get the message from the wrong portion of the request meaning that no email was ever sent at least when removing someone from a group or party.
I can fix this issue but I'm wondering what the expected format is for the optional message that the user can provide. Do we want to use the message above and just add an optional portion to the email below it passing the user generated message through if it exists?
I'm not seeing a place to add the new email text. Is this somewhere in the locale file that I'm just missing?
@Hus274 when a member is booted from a group they should receive an email even if the custom message isn't passed. If it doesn't work like this it's a bug.
Regarding emails text they're stored on our email provider, if you provide me with the text I'll add it before any code goes live
I apparently lost track of this issue at some point and just found it a day ago. Sorry for the delay on this, I've posted a pull-request now!
@Hus274 no worries, we're usually the ones who lose track of PRs :)
Most helpful comment
Yes, this makes sense. Perhaps it should have the same subject line so that it could thread?
As for the body of the email, let's do:
"Your Party invitation has been rescinded by the party leader, so your invitation link will no longer work. To find a different Party, try posting in the Party Wanted Guild. Good luck!"