function oa_update_update_status_alter in Open Atrium Core 7.2
Implements hook_update_status_alter().
File
- modules/
oa_update/ oa_update.module, line 222 - Code for the oa_update module
Code
function oa_update_update_status_alter(&$projects) {
$profile_name = drupal_get_profile();
foreach ($projects as $key => $project) {
// -dev versions with patches are marked as NOT_SUPPORTED
// but for a Distribution, these modules are Current
if ($project['status'] == UPDATE_NOT_SUPPORTED) {
$projects[$key]['status'] = UPDATE_CURRENT;
}
}
if (!variable_get('oa_update_enable', FALSE)) {
// we want to supress the update messages for non-security updates
foreach ($projects as $key => $project) {
// mark anything that isn't a security update as ok
// don't change status of distribution version
if ($key != $profile_name && $project['status'] !== UPDATE_NOT_SECURE) {
$projects[$key]['status'] = UPDATE_CURRENT;
}
}
}
}