Skip to content
Snippets Groups Projects
Commit 15405e8b authored by Tim Steiner's avatar Tim Steiner
Browse files

[gh-155] Merging from testing into staging

git-svn-id: file:///tmp/wdn_thm_drupal/branches/drupal-7.x/staging@766 20a16fea-79d4-4915-8869-1ea9d5ebf173
parent f9c42799
No related branches found
No related tags found
No related merge requests found
...@@ -481,14 +481,15 @@ function unl_cron() { ...@@ -481,14 +481,15 @@ function unl_cron() {
} }
Database::addConnectionInfo('wdn_registry', 'default', $wdn_registry_info); Database::addConnectionInfo('wdn_registry', 'default', $wdn_registry_info);
db_set_active('wdn_registry');
try { try {
db_set_active('wdn_registry');
$data = db_select('site_request', 'r') $data = db_select('site_request', 'r')
->fields('r') ->fields('r')
->where('`url` IS NULL') ->where('`url` IS NULL')
->execute() ->execute()
->fetchAll(); ->fetchAll();
db_set_active();
} }
catch (Exception $e) { catch (Exception $e) {
db_set_active(); db_set_active();
...@@ -524,15 +525,16 @@ function unl_cron() { ...@@ -524,15 +525,16 @@ function unl_cron() {
'department' => $full_department, 'department' => $full_department,
); );
db_set_active('wdn_registry');
if (variable_get('unl_wdn_registry_production')) { if (variable_get('unl_wdn_registry_production')) {
db_update('site_request') db_update('site_request')
->fields(array('url' => url($path))) ->fields(array('url' => url($path)))
->condition('id', $site->id) ->condition('id', $site->id)
->execute(); ->execute();
} }
db_set_active();
} }
db_set_active();
foreach ($sites_to_create as $site_to_create) { foreach ($sites_to_create as $site_to_create) {
try { try {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment