src/Extensions/BetterButtonDataObject.php
protected function createFieldList($buttons)
    {
        $actions = FieldList::create();
        foreach ($buttons as $buttonType => $bool) {
            if (!$bool || !$buttonType) {
                continue;
            }

            if (substr($buttonType, 0, 6) == "Group_") {
                $group = $this->createButtonGroup(substr($buttonType, 6));
                if ($group->children->exists()) {
                    $actions->push($group);
                }
            } elseif ($b = $this->instantiateButton($buttonType)) {
                $actions->push($b);
            }
        }

        return $actions;
    }
protected function createFieldList($buttons)
    {
        $actions = FieldList::create();
        foreach ($buttons as $buttonType => $bool) {
            if (!$bool || !$buttonType) {
                continue;
            }

            if (substr($buttonType, 0, 6) == "Group_") {
                $group = $this->createButtonGroup(substr($buttonType, 6));
                if ($group->children->exists()) {
                    $actions->push($group);
                }
            } elseif ($b = $this->instantiateButton($buttonType)) {
                $actions->push($b);
            }
        }

        return $actions;
    }
Transforms a list of configured buttons into a usable FieldList
@param  array                            $buttons An array of class names
@return FieldList