src/User/UserField.php
protected function getSection(FieldTypeInterface $field, $section = null): SectionInterface
    {
        if (is_null($section)) {
            if ($this->repository->hasGroup($field->getOption('group'))) {
                $section = $this->repository->getGroup($field->getOption('group'));
            } else {
                $section = new Section($field->getOption('group'));
            }

            $section->addItem($field);
        }

        return $section;
    }
protected function getSection(FieldTypeInterface $field, $section = null): SectionInterface
    {
        if (is_null($section)) {
            if ($this->repository->hasGroup($field->getOption('group'))) {
                $section = $this->repository->getGroup($field->getOption('group'));
            } else {
                $section = new Section($field->getOption('group'));
            }

            $section->addItem($field);
        }

        return $section;
    }
protected function getSection ( FieldTypeInterface $ field , $ section = null ) : SectionInterface { if ( is_null ( $ section ) ) { if ( $ this -> repository -> hasGroup ( $ field -> getOption ( 'group' ) ) ) { $ section = $ this -> repository -> getGroup ( $ field -> getOption ( 'group' ) ) ; } else { $ section = new Section ( $ field -> getOption ( 'group' ) ) ; } $ section -> addItem ( $ field ) ; } return $ section ; }
Get section for given field.

@param FieldTypeInterface $field
@param null               $section

@return SectionInterface
Get section for given field .