diff --git a/src/main/scala/gitbucket/core/util/Notifier.scala b/src/main/scala/gitbucket/core/util/Notifier.scala index 54b01e309..7eed79884 100644 --- a/src/main/scala/gitbucket/core/util/Notifier.scala +++ b/src/main/scala/gitbucket/core/util/Notifier.scala @@ -87,7 +87,7 @@ class Mailer(private val smtp: Smtp) extends Notifier { email.setSSLOnConnect(ssl) } smtp.fromAddress - .map (_ -> smtp.fromName.orNull) + .map (_ -> smtp.fromName.getOrElse(context.loginAccount.get.userName)) .orElse (Some("notifications@gitbucket.com" -> context.loginAccount.get.userName)) .foreach { case (address, name) => email.setFrom(address, name)