At libraries.api.php is:

 *     - pattern: A string containing a regular expression (PCRE) to match the
 *       library version. For example: '@version\s+([0-9a-zA-Z\.-]+)@'. Note
 *       that the returned version is not the match of the entire pattern (i.e.
 *       '@version 1.2.3' in the above example) but the match of the first
 *       sub-pattern (i.e. '1.2.3' in the above example).

It is not correct. preg_match requires "/" at begin and end of a pattern, so it should be there also.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

aritrika.d’s picture

please review the patch

aritrika.d’s picture

Status: Active » Needs review