I am trying to compare a value inside an array, that is initialized before array_filter is called.
The array is not empty but becomes equal to null when the control flows inside the callback function of array_filter. What could be the reason for this?
$stream = $stream_list[$i]['@attributes']; // IS ARRAY
$chargeable_feature = array_filter($applicable_conversions,function($conversion) {
return $conversion['FeatureName'] == $stream['FeaturesUsed'];
// STREAM BECOMES NULL HERE
});