User tests: Successful: Unsuccessful:
Pull Request for Issue #9881
Too much copy/pasting led to the wrong variable being used in the sendAdminMail()
method. This fixes it.
Code review. See 7fcf7f6#diff-98e863dabf8033c2313bc92e9c99cc2fL615 to see how the variable changed and how this corrects it back.
Status | New | ⇒ | Pending |
Labels |
Added:
?
|
I have tested this item
on code review
Why not make it work like anybody would expect: respect the third parameter $email and use it to send the email to. It is not much use to send it to the site admin!
EDIT: My bad, the second parameter is the recipient email which makes $email obsolete. The naming is very confusing, it can be anybody's email. The calling program determines that. It doesn't have to be the site administrator or an administrator at all. The calling program can invent the name and email as they want.
I've never used the method so I don't know what the expectation is honestly. For now this PR just fixes the behavior I broke by using a bad variable. Though by the method name just at a guess I'd say sendAdminMail()
should be sending an admin an email, but why that needs a dedicated method that you still have to pass an email address to (with no validation it's actually an admin receiving the message) seems odd to say the least.
this was created (see doc bloc) specifically imho to send mail to admin when a user has submitted new item in frontend. that's why i think it is never used... and we have no lang strings
That explains why it is not used in the content plugin. There they implemented it for all that are to receive mails (sendEmail = 1).
Milestone |
Added: |
Status | Pending | ⇒ | Ready to Commit |
Milestone |
Removed: |
Milestone |
Added: |
Milestone |
Added: |
Labels |
Added:
?
|
Status | Ready to Commit | ⇒ | Fixed in Code Base |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2016-05-26 16:01:31 |
Closed_By | ⇒ | Kubik-Rubik |
Labels |
Removed:
?
|
I have tested this item✅ successfully on 37b2f4f
This comment was created with the J!Tracker Application at issues.joomla.org/joomla-cms/10633.