Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Link addition to email for marking comment as spam #3163

Merged
merged 1 commit into from
Aug 1, 2018

Conversation

grvsachdeva
Copy link
Member

Fixes #3137

Make sure these boxes are checked before your pull request (PR) is ready to be reviewed and merged. Thanks!

  • tests pass -- look for a green checkbox ✔️ a few minutes after opening your PR -- or run tests locally with rake test
  • code is in uniquely-named feature branch and has no merge conflicts
  • PR is descriptively titled
  • PR body includes fixes #0000-style reference to original issue #
  • ask @publiclab/reviewers for help, in a comment below

We're happy to help you get this ready -- don't be afraid to ask for help, and don't be discouraged if your tests fail at first!

If tests do fail, click on the red X to learn why by reading the logs.

Please be sure you've reviewed our contribution guidelines at https://publiclab.org/contributing-to-public-lab-software

We have a loose schedule of reviewing and pulling in changes every Tuesday and Friday, and publishing changes on Fridays.

Thanks!

@ghost ghost assigned grvsachdeva Jul 28, 2018
@ghost ghost added the in progress label Jul 28, 2018
@grvsachdeva
Copy link
Member Author

Hi @jywarren @publiclab/soc anyone facing this issue

octokit

Thanks!

@stefannibrasil
Copy link

we are having the same error on #3114 and #3134

@grvsachdeva
Copy link
Member Author

yes @stefannibrasil, my previous PR #3140 also failed. Let's wait for @jywarren and @icarito .

@plotsbot
Copy link
Collaborator

1 Message
📖 @Gauravano Thank you for your pull request! I’m here to help with some tips and recommendations. Please take a look at the list provided and help us review and accept your contribution! And don’t be discouraged if you see errors – we’re here to help.

Generated by 🚫 Danger

@grvsachdeva
Copy link
Member Author

@jywarren please review this PR. Thanks!

@grvsachdeva grvsachdeva requested a review from jywarren August 1, 2018 06:58
@@ -14,6 +14,13 @@ Hi! There's been a response to a discussion you're involved in. Do NOT reply to

<hr />

<p>Look like spam?
<% if @user.can_moderate? %>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So here's what I'm worried about, are we notifying in a bulk BCC, or do we actually have unique user record each time it's sent?

I can't find where this is used to see what the @user variable is, but let's check!

https://github.com/publiclab/plots2/search?q=CommentMailer.notify&unscoped_q=CommentMailer.notify

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Each time a new comment is created this CommentMailer.notify send emails to users subscribed to the tags or node. So, I have added these buttons only on normal notification emails.
Here's the effective mailer https://github.com/publiclab/plots2/blob/master/app/mailers/comment_mailer.rb#L7-L12

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeah, that's great! I just want to know where user is specified -- like, do you know where this .notify() is called from, so we can be sure it represents the recipient user instead of the comment author? I think we may want to rename the parameter a little bit to be sure of it, since user is ambiguous, you know?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jywarren
Copy link
Member

jywarren commented Aug 1, 2018 via email

@grvsachdeva
Copy link
Member Author

grvsachdeva commented Aug 1, 2018

@jywarren I can change the name but the whole comment_mailer.rb file is using @ user. So, should I change it to recipient in notify_method only or everywhere. Thanks!

@jywarren
Copy link
Member

jywarren commented Aug 1, 2018

ok, well we can also do that in a follow-up PR. OK, let's see how this does!

@jywarren jywarren merged commit 996933c into publiclab:master Aug 1, 2018
@ghost ghost removed the ready label Aug 1, 2018
stefannibrasil pushed a commit to milaaraujo/plots2 that referenced this pull request Aug 3, 2018
SrinandanPai pushed a commit to SrinandanPai/plots2 that referenced this pull request May 5, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add link to approve/spam comments in comment email notifications to moderators
4 participants