Skip to content

Commit

Permalink
MDL-60347 core: debugsmtp should be a developer only setting.
Browse files Browse the repository at this point in the history
  • Loading branch information
danmarsden authored and stronk7 committed Jul 1, 2019
1 parent 7a5e858 commit 8c678d9
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lang/en/admin.php
Expand Up @@ -197,7 +197,7 @@
$string['configdebug'] = 'If you turn this on, then PHP\'s error_reporting will be increased so that more warnings are printed. This is only useful for developers.';
$string['configdebugdisplay'] = 'Set to on, the error reporting will go to the HTML page. This is practical, but breaks XHTML, JS, cookies and HTTP headers in general. Set to off, it will send the output to your server logs, allowing better debugging. The PHP setting error_log controls which log this goes to.';
$string['configdebugpageinfo'] = 'Enable if you want page information printed in page footer.';
$string['configdebugsmtp'] = 'Enable verbose debug information during sending of email messages to SMTP server.';
$string['configdebugsmtp'] = 'Enable verbose debug information during sending of email messages to SMTP server. For this setting to take effect, the \'Debug messages\' setting must be set to \'Developer\'.';
$string['configdebugvalidators'] = 'Enable if you want to have links to external validator servers in page footer. You may need to create new user with username <em>w3cvalidator</em>, and enable guest access. These changes may allow unauthorized access to server, do not enable on production sites!';
$string['configdefaulthomepage'] = 'This determines the home page for logged in users';
$string['configdefaultrequestcategory'] = 'Courses requested by users will be automatically placed in this category.';
Expand Down
2 changes: 1 addition & 1 deletion lib/moodlelib.php
Expand Up @@ -5676,7 +5676,7 @@ function get_mailer($action='get') {
} else {
// Use SMTP directly.
$mailer->isSMTP();
if (!empty($CFG->debugsmtp)) {
if (!empty($CFG->debugsmtp) && (!empty($CFG->debugdeveloper))) {
$mailer->SMTPDebug = 3;
}
// Specify main and backup servers.
Expand Down

0 comments on commit 8c678d9

Please sign in to comment.