Changeset 1998


Ignore:
Timestamp:
May 4, 2007, 11:54:23 PM (17 years ago)
Author:
plg
Message:

Bug 679 fixed: avoid involuntarily upgrading more than once. A check of
existing tables/columns was added to make sure the upgrade is not a refresh.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/branch-1_7/upgrade.php

    r1944 r1998  
    155155// +-----------------------------------------------------------------------+
    156156
     157$tables = get_tables();
     158$columns_of = get_columns_of($tables);
     159
    157160if (!isset($_GET['version']))
    158161{
    159162  // find the current release
    160   $tables = get_tables();
    161   $columns_of = get_columns_of($tables);
    162 
    163163  if (!in_array('param', $columns_of[PREFIX_TABLE.'config']))
    164164  {
     
    213213else
    214214{
     215  if (in_array(PREFIX_TABLE.'history_summary', $tables))
     216  {
     217    die('No database upgrade required, do not refresh the page');
     218  }
     219   
    215220  $upgrade_file = PHPWG_ROOT_PATH.'install/upgrade_'.$_GET['version'].'.php';
    216221  if (is_file($upgrade_file))
Note: See TracChangeset for help on using the changeset viewer.