celyes / ray

Ray is a fluent way to access arrays in PHP
MIT License
1 stars 0 forks source link

Element class named constructor should return Element instance #2

Open cherifGsoul opened 1 year ago

cherifGsoul commented 1 year ago

Line https://github.com/celyes/ray/blob/946a91b4057723632d6e813771bc1ec7368b9143/src/Element.php#L27

I would not make an instance of class A inside class B where A is Ray and B is Element.

celyes commented 1 year ago

This is not the best solution to work with nested arrays indeed. I'll fix the issue ASAP. Thank you!