Invalidates cached data relating to update status.
$cid: (optional) Cache ID of the record to clear from the private update module cache. If empty, all records will be cleared from the table except fetch tasks. Defaults to NULL.
$wildcard: (optional) If TRUE, cache IDs starting with $cid are deleted in addition to the exact cache ID specified by $cid. Defaults to FALSE.
function _update_cache_clear($cid = NULL, $wildcard = FALSE) {
if (empty($cid)) {
db_delete('cache_update')
->condition('cid', 'fetch_task::%', 'NOT LIKE')
->execute();
}
else {
$query = db_delete('cache_update');
if ($wildcard) {
$query
->condition('cid', $cid . '%', 'LIKE');
}
else {
$query
->condition('cid', $cid);
}
$query
->execute();
}
}