protected function _debugExpectedFields($expectedFields = [], $missingMessage = '')
    {
        if (count($expectedFields) === 0) {
            return null;
        }

        $expectedFieldNames = [];
        foreach ((array)$expectedFields as $key => $expectedField) {
            if (is_int($key)) {
                $expectedFieldNames[] = $expectedField;
            } else {
                $expectedFieldNames[] = $key;
            }
        }

        return sprintf($missingMessage, implode(', ', $expectedFieldNames));
    }
protected function _debugExpectedFields($expectedFields = [], $missingMessage = '')
    {
        if (count($expectedFields) === 0) {
            return null;
        }

        $expectedFieldNames = [];
        foreach ((array)$expectedFields as $key => $expectedField) {
            if (is_int($key)) {
                $expectedFieldNames[] = $expectedField;
            } else {
                $expectedFieldNames[] = $key;
            }
        }

        return sprintf($missingMessage, implode(', ', $expectedFieldNames));
    }
protected function _debugExpectedFields ( $ expectedFields = [ ] , $ missingMessage = '' ) { if ( count ( $ expectedFields ) === 0 ) { return null ; } $ expectedFieldNames = [ ] ; foreach ( ( array ) $ expectedFields as $ key => $ expectedField ) { if ( is_int ( $ key ) ) { $ expectedFieldNames [ ] = $ expectedField ; } else { $ expectedFieldNames [ ] = $ key ; } } return sprintf ( $ missingMessage , implode ( ', ' , $ expectedFieldNames ) ) ; }
Generate debug message for the expected fields

@param array $expectedFields Expected fields
@param string $missingMessage Message template
@return string|null Error message about expected fields
Generate debug message for the expected fields