mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-08 04:18:52 +00:00
[ticket/12763] Remove empty schema files
PHPBB3-12763
This commit is contained in:
parent
e45cd32de7
commit
3fd7fd435d
7 changed files with 24 additions and 45 deletions
|
@ -1153,6 +1153,9 @@ class install_install extends module
|
||||||
|
|
||||||
// How should we treat this schema?
|
// How should we treat this schema?
|
||||||
$delimiter = $available_dbms[$data['dbms']]['DELIM'];
|
$delimiter = $available_dbms[$data['dbms']]['DELIM'];
|
||||||
|
|
||||||
|
if (file_exists($dbms_schema))
|
||||||
|
{
|
||||||
$sql_query = @file_get_contents($dbms_schema);
|
$sql_query = @file_get_contents($dbms_schema);
|
||||||
$sql_query = preg_replace('#phpbb_#i', $data['table_prefix'], $sql_query);
|
$sql_query = preg_replace('#phpbb_#i', $data['table_prefix'], $sql_query);
|
||||||
$sql_query = phpbb_remove_comments($sql_query);
|
$sql_query = phpbb_remove_comments($sql_query);
|
||||||
|
@ -1168,6 +1171,7 @@ class install_install extends module
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
unset($sql_query);
|
unset($sql_query);
|
||||||
|
}
|
||||||
|
|
||||||
// Ok we have the db info go ahead and work on building the table
|
// Ok we have the db info go ahead and work on building the table
|
||||||
$db_table_schema = @file_get_contents('schemas/schema.json');
|
$db_table_schema = @file_get_contents('schemas/schema.json');
|
||||||
|
|
|
@ -1,5 +0,0 @@
|
||||||
# DO NOT EDIT THIS FILE, IT IS GENERATED
|
|
||||||
#
|
|
||||||
# To change the contents of this file, edit
|
|
||||||
# phpBB/develop/create_schema_files.php and
|
|
||||||
# run it.
|
|
|
@ -1,8 +0,0 @@
|
||||||
/*
|
|
||||||
* DO NOT EDIT THIS FILE, IT IS GENERATED
|
|
||||||
*
|
|
||||||
* To change the contents of this file, edit
|
|
||||||
* phpBB/develop/create_schema_files.php and
|
|
||||||
* run it.
|
|
||||||
*/
|
|
||||||
|
|
|
@ -1,5 +0,0 @@
|
||||||
# DO NOT EDIT THIS FILE, IT IS GENERATED
|
|
||||||
#
|
|
||||||
# To change the contents of this file, edit
|
|
||||||
# phpBB/develop/create_schema_files.php and
|
|
||||||
# run it.
|
|
|
@ -1,5 +0,0 @@
|
||||||
# DO NOT EDIT THIS FILE, IT IS GENERATED
|
|
||||||
#
|
|
||||||
# To change the contents of this file, edit
|
|
||||||
# phpBB/develop/create_schema_files.php and
|
|
||||||
# run it.
|
|
|
@ -1,5 +0,0 @@
|
||||||
# DO NOT EDIT THIS FILE, IT IS GENERATED
|
|
||||||
#
|
|
||||||
# To change the contents of this file, edit
|
|
||||||
# phpBB/develop/create_schema_files.php and
|
|
||||||
# run it.
|
|
|
@ -342,6 +342,8 @@ class phpbb_database_test_connection_manager
|
||||||
|
|
||||||
$filename = $directory . $schema . '_schema.sql';
|
$filename = $directory . $schema . '_schema.sql';
|
||||||
|
|
||||||
|
if (file_exists($filename))
|
||||||
|
{
|
||||||
$queries = file_get_contents($filename);
|
$queries = file_get_contents($filename);
|
||||||
$sql = phpbb_remove_comments($queries);
|
$sql = phpbb_remove_comments($queries);
|
||||||
|
|
||||||
|
@ -351,6 +353,7 @@ class phpbb_database_test_connection_manager
|
||||||
{
|
{
|
||||||
$this->pdo->exec($query);
|
$this->pdo->exec($query);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Ok we have the db info go ahead and work on building the table
|
// Ok we have the db info go ahead and work on building the table
|
||||||
$db_table_schema = file_get_contents($directory . 'schema.json');
|
$db_table_schema = file_get_contents($directory . 'schema.json');
|
||||||
|
|
Loading…
Add table
Reference in a new issue