drupal_check_incompatibility($v, $current_version)Check whether a version is compatible with a given dependency.
$v The parsed dependency structure from drupal_parse_dependency().
$current_version The version to check against (like 4.2).
NULL if compatible, otherwise the original dependency version string that caused the incompatibility.
includes/common.inc, line 6209
<?php
function drupal_check_incompatibility($v, $current_version) {
if (!empty($v['versions'])) {
foreach ($v['versions'] as $required_version) {
if ((isset($required_version['op']) && !version_compare($current_version, $required_version['version'], $required_version['op']))) {
return $v['original_version'];
}
}
}
}
?>