function _rules_upgrade_fetch_all_rules
Fetches all rules.
2 calls to _rules_upgrade_fetch_all_rules()
- rules_upgrade_convert_rule_set in includes/
rules.upgrade.inc - Converts a single rule set, including all of its rules.
- rules_upgrade_form in includes/
rules.upgrade.inc - Form builder for the upgrade page.
File
-
includes/
rules.upgrade.inc, line 163
Code
function _rules_upgrade_fetch_all_rules() {
$static = drupal_static(__FUNCTION__);
if (!isset($static)) {
$query = db_select('rules_rules', 'r')->fields('r');
$static['rules'] = array();
foreach ($query->execute() as $row) {
$static['rules'][$row->name] = unserialize($row->data);
}
}
return $static['rules'];
}