0) { $last_summarized = $history_lines[0]; list($year, $month, $day) = explode('-', $last_summarized['date']); list($hour) = explode(':', $last_summarized['time']); single_update( PREFIX_TABLE.'history_summary', array( 'history_id_to' => $last_summarized['id'], ), array( 'year' => $year, 'month' => $month, 'day' => $day, 'hour' => $hour, ) ); // in case this script would update no summary line, it would mean the // summary has been purged and will be rebuild from scratch, based on the // content of history table } // for now, we keep column history.summarized even if Piwigo 2.9 no longer // uses it. We will remove it in a future version. First we need to have // "less" lines in history table. This will be possible with the automatic // purge implemented in Piwigo 2.9. echo "\n".$upgrade_description."\n"; ?>