image lazy load

This commit is contained in:
xiaomlove
2022-08-31 23:08:26 +08:00
parent 8d3d404141
commit 138ee2b86a
7 changed files with 100 additions and 7 deletions

View File

@@ -91,7 +91,7 @@ class Update extends Install
*/
foreach (['adminpanel', 'modpanel', 'sysoppanel'] as $table) {
$columnInfo = NexusDB::getMysqlColumnInfo($table, 'id');
if ($columnInfo['DATA_TYPE'] == 'tinyint') {
if ($columnInfo['DATA_TYPE'] == 'tinyint' || empty($columnInfo['EXTRA']) || $columnInfo['EXTRA'] != 'auto_increment') {
sql_query("alter table $table modify id int(11) unsigned not null AUTO_INCREMENT");
}
}