mirror of
https://github.com/friendica/friendica
synced 2025-04-26 01:10:15 +00:00
The database structure is now checked ad the admin summary page
This commit is contained in:
parent
9418c000a1
commit
104acec09c
2 changed files with 19 additions and 4 deletions
|
@ -8,6 +8,10 @@ require_once("include/text.php");
|
|||
|
||||
define('NEW_UPDATE_ROUTINE_VERSION', 1170);
|
||||
|
||||
const DB_UPDATE_NOT_CHECKED = 0; // Database check wasn't executed before
|
||||
const DB_UPDATE_SUCCESSFUL = 1; // Database check was successful
|
||||
const DB_UPDATE_FAILED = 2; // Database check failed
|
||||
|
||||
/*
|
||||
* Converts all tables from MyISAM to InnoDB
|
||||
*/
|
||||
|
@ -480,6 +484,12 @@ function update_structure($verbose, $action, $tables=null, $definition=null) {
|
|||
Config::set('system', 'maintenance_reason', '');
|
||||
}
|
||||
|
||||
if ($errors) {
|
||||
Config::set('system', 'dbupdate', DB_UPDATE_FAILED);
|
||||
} else {
|
||||
Config::set('system', 'dbupdate', DB_UPDATE_SUCCESSFUL);
|
||||
}
|
||||
|
||||
return $errors;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue