diff options
author | Joas Schilling <nickvergessen@gmx.de> | 2014-06-30 11:22:20 +0200 |
---|---|---|
committer | Joas Schilling <nickvergessen@gmx.de> | 2014-06-30 11:22:20 +0200 |
commit | d94d307f522ce724ac288f57f563338f7229db4c (patch) | |
tree | d278601d8ecf45b4036ed0534268737db4353d91 /settings | |
parent | 589f68ebf6dde3f0a804732a716bb6fd18363e00 (diff) | |
parent | 6e2aaaaa31afc31b0ed216ded52b3b0ab9eb61ad (diff) | |
download | nextcloud-server-d94d307f522ce724ac288f57f563338f7229db4c.tar.gz nextcloud-server-d94d307f522ce724ac288f57f563338f7229db4c.zip |
Merge pull request #9207 from owncloud/prevent-default-for-mail-test
Fix test mail behaviour
Diffstat (limited to 'settings')
-rw-r--r-- | settings/admin/controller.php | 2 | ||||
-rw-r--r-- | settings/js/admin.js | 6 |
2 files changed, 4 insertions, 4 deletions
diff --git a/settings/admin/controller.php b/settings/admin/controller.php index d0dcc49f297..7ced57791e9 100644 --- a/settings/admin/controller.php +++ b/settings/admin/controller.php @@ -86,7 +86,7 @@ class Controller { $defaults = new \OC_Defaults(); try { - \OC_Mail::send($email, $_POST['user'], + \OC_Mail::send($email, \OC_User::getDisplayName(), $l->t('test email settings'), $l->t('If you received this email, the settings seem to be correct.'), \OCP\Util::getDefaultEmailAddress('no-reply'), $defaults->getName()); diff --git a/settings/js/admin.js b/settings/js/admin.js index 7036f6dbf2a..a202feb4f65 100644 --- a/settings/js/admin.js +++ b/settings/js/admin.js @@ -123,10 +123,10 @@ $(document).ready(function(){ }); }); - $('#sendtestemail').click(function(){ + $('#sendtestemail').click(function(event){ + event.preventDefault(); OC.msg.startAction('#sendtestmail_msg', t('settings', 'Sending...')); - var post = $( "#sendtestemail" ).serialize(); - $.post(OC.generateUrl('/settings/admin/mailtest'), post, function(data){ + $.post(OC.generateUrl('/settings/admin/mailtest'), '', function(data){ OC.msg.finishedAction('#sendtestmail_msg', data); }); }); |