$start = $dbw->selectField( 'user_groups', 'MIN(ug_user)',
[ 'ug_group' => $oldGroup ], __FUNCTION__ );
$end = $dbw->selectField( 'user_groups', 'MAX(ug_user)',
[ 'ug_group' => $oldGroup ], __FUNCTION__ );
if ( $start === null ) {
$start = $dbw->selectField( 'user_groups', 'MIN(ug_user)',
[ 'ug_group' => $oldGroup ], __FUNCTION__ );
$end = $dbw->selectField( 'user_groups', 'MAX(ug_user)',
[ 'ug_group' => $oldGroup ], __FUNCTION__ );
if ( $start === null ) {