mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-07 23:16:13 +02:00
[ticket/11525] Prefix id parameter with 'g' again when its a group avatar
PHPBB3-11525
This commit is contained in:
parent
47f2caff6b
commit
aa84f7de04
@ -183,8 +183,9 @@ class manager
|
||||
* @param array $row User data or group data
|
||||
* @param string $prefix Prefix of data keys (e.g. user), should not include the trailing underscore
|
||||
*
|
||||
* @return array User data or group data with keys that have been
|
||||
* stripped from the preceding "user_" or "group_"
|
||||
* @return array User or group data with keys that have been
|
||||
* stripped from the preceding "user_" or "group_"
|
||||
* Also the group id is prefixed with g, when the prefix group is removed.
|
||||
*/
|
||||
static public function clean_row($row, $prefix = '')
|
||||
{
|
||||
@ -198,8 +199,14 @@ class manager
|
||||
$values = array_values($row);
|
||||
|
||||
array_walk($keys, array('\phpbb\avatar\manager', 'strip_prefix'), $prefix);
|
||||
$row = array_combine($keys, $values);
|
||||
|
||||
return array_combine($keys, $values);
|
||||
if ($prefix == 'group')
|
||||
{
|
||||
$row['id'] = 'g' . $row['id'];
|
||||
}
|
||||
|
||||
return $row;
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
x
Reference in New Issue
Block a user