Skip to content

Could not load type "Symfony\Component\Form\Extension\Core\Type\HiddenType" #11

@emirii

Description

@emirii

In Symfony 2.7.10/2.7.9 the latest update breaks, with any form type using hidden_entity:

Could not load type "Symfony\Component\Form\Extension\Core\Type\HiddenType"

This commit here:
b9cf834

    /**
     * Set the parent form type to Symfony core HiddenType
     *
     * TODO: when drop Symfony 2.x support, add use statement above
     *       for HiddenType core class and return HiddenType::class
     *       here instead of path string
     *
     * @return string
     */
    public function getParent()
    {
        return 'hidden';
    }

I just change getParent to return 'hidden' instead of the class name and it works again. Not sure what else to do to help... but just a heads up.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions