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

Undefined array key "source" #69

Open
taradaidv opened this issue Mar 11, 2023 · 1 comment
Open

Undefined array key "source" #69

taradaidv opened this issue Mar 11, 2023 · 1 comment

Comments

@taradaidv
Copy link

taradaidv commented Mar 11, 2023

Привет!
Не хватает проверки "source".
Если создать lvm через lxd init тогда пропадет "source" что приведет к Undefined array key из-за чего сломается json ответ и в итоге не отрисуется список storage-pools.
Для фикса надо сделать предварительную проверку key в array.

echo '"' . htmlentities($storage_pool['config']['source']) . '",';

 if (!empty($device_array['config']['source'])){
              echo '"' . htmlentities($storage_pool['config']['source']) . '",';
            } else {
              echo '"---",';
            }
@matthewalanpenning
Copy link
Contributor

Thank you. This is a good find. I will add this in the next release v3.7.0

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

No branches or pull requests

2 participants