diff --git a/lib/mail.php b/lib/mail.php
index 0becb182b23491c1ca78ae6a3373fc6d8386bc97..a4e3a39feeb261fb27b221fcc59d990f46ca8144 100644
--- a/lib/mail.php
+++ b/lib/mail.php
@@ -81,7 +81,7 @@ class OC_Mail {
 
 			$mailo->Send();
 			unset($mailo);
-			OC_Log::write('Mail from '.$fromname.' ('.$fromaddress.')'.' to: '.$toname.'('.$toaddress.')'.' subject: '.$subject,'mail',OC_Log::DEBUG);
+			OC_Log::write('mail', 'Mail from '.$fromname.' ('.$fromaddress.')'.' to: '.$toname.'('.$toaddress.')'.' subject: '.$subject, OC_Log::DEBUG);
 		} catch (Exception $exception) {
 			OC_Log::write('mail', $exception->getMessage(), OC_Log::DEBUG);
 		}