Skip to content

Mistake in example ChoicesRepository #190

Description

@karelVanGeerdeghom

Hello,

In the ChoicesRepository class, in the getChoices method I see this code:

    foreach ($values as $value) {
        $choices[$value->getId()] = $value->getCode();
    }

I had to change this to

    foreach ($values as $value) {
        $choices[$value->getCode()] = $value->getId();
    }

to get it to work.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions