Commit af3c8682 authored by drumm's avatar drumm
Browse files

Issue #3117465: Update the project_nid column, too

parent ef6d2648
......@@ -183,7 +183,7 @@ function drush_project_usage_import_usage_stats($week) {
// Load in new counts.
$qcount = 0;
$query = db_insert('project_usage_week_release')
->fields(['nid', 'timestamp', 'count']);
->fields(['nid', 'project_nid', 'timestamp', 'count']);
foreach ($release_counts as $project_machine_name => $releases) {
foreach ($releases as $nid => $count) {
$qcount++;
......@@ -199,7 +199,7 @@ function drush_project_usage_import_usage_stats($week) {
$query->execute();
$qcount = 0;
$query = db_insert('project_usage_week_release')
->fields(['nid', 'timestamp', 'count']);
->fields(['nid', 'project_nid', 'timestamp', 'count']);
}
}
if ($qcount) {
......@@ -253,5 +253,4 @@ function drush_project_usage_import_usage_stats($week) {
drush_log(dt("End updating @week tallies on database.", array('@week' => $week)));
project_usage_get_active_weeks(TRUE);
}
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment