From 5431aa6391571a1de11fe338f6064ad87aa6f7df Mon Sep 17 00:00:00 2001
From: rxu <rxu@mail.ru>
Date: Mon, 27 Oct 2014 00:36:58 +0700
Subject: [PATCH] [ticket/13223] Fix USERNAME email template variable in
 notification

admin_activate_user.php notification type is assigning usernames to email
template variables using user_loader->get_username() in 'no_profile' mode,
which in its turn calls get_username_string() function in 'no_profile' mode.
This causes HTML markup in emails for username colour.

PHPBB3-13223
---
 phpBB/phpbb/notification/type/admin_activate_user.php | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/phpBB/phpbb/notification/type/admin_activate_user.php b/phpBB/phpbb/notification/type/admin_activate_user.php
index 038ca3726e..dfc0157558 100644
--- a/phpBB/phpbb/notification/type/admin_activate_user.php
+++ b/phpBB/phpbb/notification/type/admin_activate_user.php
@@ -131,7 +131,7 @@ class admin_activate_user extends \phpbb\notification\type\base
 	public function get_email_template_variables()
 	{
 		$board_url = generate_board_url();
-		$username = $this->user_loader->get_username($this->item_id, 'no_profile');
+		$username = $this->user_loader->get_username($this->item_id, 'username');
 
 		return array(
 			'USERNAME'			=> htmlspecialchars_decode($username),