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

$callback - Invalid argument supplied for foreach() #424

Open
lowap opened this issue Jul 1, 2019 · 1 comment
Open

$callback - Invalid argument supplied for foreach() #424

lowap opened this issue Jul 1, 2019 · 1 comment

Comments

@lowap
Copy link

lowap commented Jul 1, 2019

Hi,

I would like to add two parameters to my route (I guess it has to go in data, right?), but as soon as I'm trying to add the callback

function($menu){
    return [
        'label' => $menu['name'], 
        'url' => [$menu['route']],
        'options' => eval($menu['data']),
        'items' => $menu['children']
    ];
}

it's throwing me

Invalid argument supplied for foreach()

Can you please point me to the right direction? Thank you!

@sihar
Copy link
Collaborator

sihar commented Mar 11, 2020

Thanks for posting in our issue tracker.
Do you have exact code to reproduce it?
Thanks!

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