Skip to content

Commit 46ea7a8

Browse files
committed
[ticket/17391] Fix PHP warning on creating group with the name already in use
PHPBB-17391
1 parent f80b41a commit 46ea7a8

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

phpBB/includes/acp/acp_groups.php

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -396,7 +396,7 @@ function main($id, $mode)
396396
$allow_desc_urls = $request->variable('desc_parse_urls', false);
397397
$allow_desc_smilies = $request->variable('desc_parse_smilies', false);
398398

399-
$submit_ary = array(
399+
$submit_ary = [
400400
'colour' => $request->variable('group_colour', ''),
401401
'rank' => $request->variable('group_rank', 0),
402402
'receive_pm' => isset($_REQUEST['group_receive_pm']) ? 1 : 0,
@@ -406,7 +406,13 @@ function main($id, $mode)
406406
'max_recipients' => $request->variable('group_max_recipients', 0),
407407
'founder_manage' => 0,
408408
'skip_auth' => $request->variable('group_skip_auth', 0),
409-
);
409+
410+
// Initialize avatar data
411+
'avatar' => $avatar_data['avatar'] ?? '',
412+
'avatar_type' => $avatar_data['avatar_type'] ?? '',
413+
'avatar_height' => $avatar_data['avatar_height'] ?? 0,
414+
'avatar_width' => $avatar_data['avatar_width'] ?? 0,
415+
];
410416

411417
if ($user->data['user_type'] == USER_FOUNDER)
412418
{

0 commit comments

Comments
 (0)