Gift Exchange: My Assignments page has email link when user has multiple assignments in an exchange
Steps to reproduce
Create a collection with a gift exchange challenge
Browse > Collections > New Collection
Fill in required information and choose "Gift Exchange" for "Type of challenge, if any"
On the exchange settings form, check "Sign-up open?"
Sign up for the exchange as at least three different users
Follow the "Sign-up Form" link in the collection sidebar
Since we accepted the default settings, we don't even need to fill anything in – just press "Submit"
If you're not already logged in as the collection owner, log back in with that account
On your collection's sidebar, follow the "Challenge Settings" link
Uncheck "Sign-up open?"
From the sidebar, follow the "Matching" link
Press "Generate Potential Matches"
You'll get a pop-up warning you matches will be random; choose "OK"
Wait briefly for matching to finish and refresh the page to see potential matches
Press "Send Assignments"
You'll get a pop-up telling you assignments will be send; choose "OK"
Default an assignment
Follow the button-style "Open" link to see all open assignments
Decide which user you want to double-assign, and check the "Default" option for the assignment that does not have that user as the recipient or giver
Double-assign the user
You'll be on the Defaulted assignments page now!
In the input field, enter the name of the person you want to double assign – you may need to enter it in the format "pseud (username)" due to
Log in as the double-assigned user
Go to the collection page
Follow the "My Assignments" link in the sidebar
Because you have multiple assignments in this challenge, you see a different page than you'd see if you only had one assignment. It's based off the page moderators see and includes an envelope icon which will allow you to email your recipient yourself, it turns out.
What should happen
That icon should not be there.
This is marked Highest because, when combined with AO3-5748, someone else’s email address may be displayed.
You can just log in as testy and make sure there is no longer an email link on the My Assignments page: https://test.archiveofourown.org/users/testy/assignments?collection_id=AO3_5748
ETA: Nope! You’ll have to log in as testy2 (or testy3) and put the correct username in this URL: https://test.archiveofourown.org/users/USERNAME/assignments?collection_id=AO3_5748. testy is a mod, so the email links will show up for them.
There should still be email links on the Assignments page for a moderator (log in as testy to check this page): https://test.archiveofourown.org/collections/AO3_5748/assignments?unfulfilled=true
Just noting that I confirmed with Briar that they tested the moderator page still had the email, too!
I tested this bug, and there weren’t any email links on my double-assigned user’s “My Assignments” page. In other words, the bug appears to be fixed! I used Firefox 69.0 on Windows 10.
Checked and both pages still had the email links.
Got halfway through making another challenge before realizing why that might be: testy is the moderator. Of course testy can see emails! It’s a little confusing that testy can see it on the My Assignments page, but it’s not exactly broken.
So I logged in as testy2 and instead checked https://test.archiveofourown.org/users/testy2/assignments?collection_id=AO3_5748.
Indeed, no email link was shown.
I’d say this is definitely fixed enough to deploy.
Whether we want to make another issue to hide the links on /users/the_moderator/assignments?collection_id is another question.