[PR #4] Fix error on fail YAML parse without exception #16

Closed
opened 2026-01-23 11:22:59 +01:00 by admin · 0 comments
Owner

Original Pull Request: https://github.com/code-rhapsodie/ezdataflow-bundle/pull/4

State: closed
Merged: Yes


Consider this code:

$val = Symfony\Component\Yaml\Yaml::parse("data1:val1\r\ndata2:val2");
dump($val);

Result:

"data1:val1 data2:val2"

The input data is a wrong YAML but no exception has been throw. This fix check if the parse result is an array and throw exception if not a array.

**Original Pull Request:** https://github.com/code-rhapsodie/ezdataflow-bundle/pull/4 **State:** closed **Merged:** Yes --- Consider this code: ```php $val = Symfony\Component\Yaml\Yaml::parse("data1:val1\r\ndata2:val2"); dump($val); ``` Result: ``` "data1:val1 data2:val2" ``` The input data is a wrong YAML but no exception has been throw. This fix check if the parse result is an array and throw exception if not a array.
admin added the pull-request label 2026-01-23 11:22:59 +01:00
admin closed this issue 2026-01-23 11:22:59 +01:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: code-rhapsodie/ezdataflow-bundle#16