summaryrefslogtreecommitdiff
path: root/installer/cli.php
diff options
context:
space:
mode:
authorBharat Mediratta <bharat@menalto.com>2009-05-13 00:32:19 +0000
committerBharat Mediratta <bharat@menalto.com>2009-05-13 00:32:19 +0000
commit7008bfb5c3b0654d7d25b2e0d0d53d09e4431c0c (patch)
tree80574dc1c08ef447cb24f31bcc511ae07f6f4cf1 /installer/cli.php
parent847de449968dfc815066eac719ddacf60639206c (diff)
Warn the user if they're attemping to reinstall into a database that
already has Gallery 3 tables. Otherwise, permit it to continue. We key this off of the existence of the g3_items table. Theoretically it's possible that the g3_items table is gone but other tables are still there, which could mess things up. I'm not going to worry about that for now. Fixes ticket #175
Diffstat (limited to 'installer/cli.php')
-rw-r--r--installer/cli.php5
1 files changed, 3 insertions, 2 deletions
diff --git a/installer/cli.php b/installer/cli.php
index a853f67b..199172dc 100644
--- a/installer/cli.php
+++ b/installer/cli.php
@@ -37,8 +37,9 @@ if (!installer::connect($config)) {
oops("Database {$config['dbname']} doesn't exist and can't be created. " .
"Please create the database by hand.");
} else if (!installer::db_empty($config)) {
- oops("Database {$config['dbname']} already has tables in it. " .
- "Please specify an empty database.\n");
+ oops("Database {$config['dbname']} already has Gallery 3 tables in it. \n" .
+ " Please remove the Gallery 3 tables, change your prefix,\n" .
+ " or specify an empty database.\n");
} else if (!installer::unpack_var()) {
oops("Unable to create files inside the 'var' directory");
} else if (!installer::unpack_sql($config)) {