Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Notice in 3.0.9 using FormHelper::input in a belongsToMany field #7061

Closed
daniouyea opened this issue Jul 19, 2015 · 1 comment
Closed

Notice in 3.0.9 using FormHelper::input in a belongsToMany field #7061

daniouyea opened this issue Jul 19, 2015 · 1 comment
Assignees
Milestone

Comments

@daniouyea
Copy link

When I update from 3.0.8 to 3.0.9 I am notified: Notice (8): Undefined index: _ids [CORE/src/View/Form/EntityContext.php, line 226]

How to reproduce:

In a template, when I edit a post (Posts belongsToMany Tags).

    echo $this->Form->create($post);
    echo $this->Form->input('tags._ids', ['options' => $tags]);
    echo $this->Form->end();

If the post has tags works fine. If the post hasn't tags fails.

@markstory markstory added this to the 3.0.10 milestone Jul 19, 2015
@markstory markstory self-assigned this Jul 19, 2015
markstory added a commit that referenced this issue Jul 20, 2015
We cannot assume that array keys will exist.

Refs #7061
@markstory
Copy link
Member

Pull request open now.

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

No branches or pull requests

2 participants