private function getPattern(string $patternId, array $patternData): array
    {
        if (array_key_exists('default', $patternData) && $patternData['default'] === true) {
            return ['pattern' => sprintf('/%s/', $patternId), 'version' => $patternId];
        }
        return ['pattern' => sprintf('/%s/', $patternData['pattern']), 'version' => array_key_exists('version', $patternData) ? $patternData['version'] : $patternId];
    }
private function getPattern(string $patternId, array $patternData): array
    {
        if (array_key_exists('default', $patternData) && $patternData['default'] === true) {
            return ['pattern' => sprintf('/%s/', $patternId), 'version' => $patternId];
        }
        return ['pattern' => sprintf('/%s/', $patternData['pattern']), 'version' => array_key_exists('version', $patternData) ? $patternData['version'] : $patternId];
    }
private function getPattern ( string $ patternId , array $ patternData ) : array { if ( array_key_exists ( 'default' , $ patternData ) && $ patternData [ 'default' ] === true ) { return [ 'pattern' => sprintf ( '/%s/' , $ patternId ) , 'version' => $ patternId ] ; } return [ 'pattern' => sprintf ( '/%s/' , $ patternData [ 'pattern' ] ) , 'version' => array_key_exists ( 'version' , $ patternData ) ? $ patternData [ 'version' ] : $ patternId ] ; }
Get pattern form array
@param string $patternId ID in config
@param array $patternData array from yaml file
@return array
Get pattern form array