@@ 197-203 (lines=7) @@ | ||
194 | $expr = $this->createArrayNode(); |
|
195 | ||
196 | foreach ($data as $key => $value) { |
|
197 | if ($value instanceof \stdClass) { |
|
198 | $nodeExpr = $this->createObjectNode(); |
|
199 | } elseif (is_array($value)) { |
|
200 | $nodeExpr = $this->createArrayNode(); |
|
201 | } else { |
|
202 | $nodeExpr = $this->createScalarNode($value); |
|
203 | } |
|
204 | ||
205 | if ($value instanceof \stdClass) { |
|
206 | $nodeExpr = $this->appendChildrenToObjectNode($value); |
|
@@ 226-232 (lines=7) @@ | ||
223 | $expr = $this->createObjectNode(); |
|
224 | ||
225 | foreach ($data as $key => $value) { |
|
226 | if ($value instanceof \stdClass) { |
|
227 | $nodeExpr = $this->createObjectNode(); |
|
228 | } elseif (is_array($value)) { |
|
229 | $nodeExpr = $this->createArrayNode(); |
|
230 | } else { |
|
231 | $nodeExpr = $this->createScalarNode($value); |
|
232 | } |
|
233 | ||
234 | if ($value instanceof \stdClass) { |
|
235 | $nodeExpr = $this->appendChildrenToObjectNode($value); |