From 8d78654c9989309b60f2c9b6cb2d53ea100a1c3d Mon Sep 17 00:00:00 2001
From: srosse <none@none>
Date: Mon, 19 Oct 2015 10:21:38 +0200
Subject: [PATCH] OO-1726: replace only with the velocity engine

---
 src/main/java/org/olat/repository/RepositoryMailing.java | 7 ++-----
 1 file changed, 2 insertions(+), 5 deletions(-)

diff --git a/src/main/java/org/olat/repository/RepositoryMailing.java b/src/main/java/org/olat/repository/RepositoryMailing.java
index 74097968bec..3f8ba50f1f7 100644
--- a/src/main/java/org/olat/repository/RepositoryMailing.java
+++ b/src/main/java/org/olat/repository/RepositoryMailing.java
@@ -79,7 +79,7 @@ public class RepositoryMailing {
 	 * @param actor
 	 * @return the generated MailTemplate
 	 */
-	public static MailTemplate createAddTutorMailTemplate(RepositoryEntry re, Identity actor) {
+	private static MailTemplate createAddTutorMailTemplate(RepositoryEntry re, Identity actor) {
 		String subjectKey = "notification.mail.added.subject";
 		String bodyKey = "notification.mail.added.body";
 		return createMailTemplate(re, actor, subjectKey, bodyKey);
@@ -92,7 +92,7 @@ public class RepositoryMailing {
 	 * @param actor
 	 * @return the generated MailTemplate
 	 */
-	public static MailTemplate createRemoveParticipantMailTemplate(RepositoryEntry re, Identity actor) {
+	private static MailTemplate createRemoveParticipantMailTemplate(RepositoryEntry re, Identity actor) {
 		String subjectKey = "notification.mail.removed.subject";
 		String bodyKey = "notification.mail.removed.body";
 		return createMailTemplate(re, actor, subjectKey, bodyKey);
@@ -174,9 +174,6 @@ public class RepositoryMailing {
 		String subject = trans.translate(subjectKey);
 		String body = trans.translate(bodyKey, bodyArgs);
 		
-		subject = subject.replaceAll("\\$coursename", reName == null ? "" : reName);
-		body = body.replaceAll("\\$coursedescription", redescription == null ? "" : redescription);
-		
 		// create a mail template which all these data
 		MailTemplate mailTempl = new MailTemplate(subject, body, null) {
 			@Override
-- 
GitLab