Add check for player_deaths columns

This commit is contained in:
slawkens 2023-04-01 15:11:12 +02:00
parent f78f5b5361
commit e9df9f10dc

View File

@ -284,7 +284,7 @@ WHERE killers.death_id = '".$death['id']."' ORDER BY killers.final_hit DESC, kil
$deaths[] = array('time' => $death['date'], 'description' => $description . '.'); $deaths[] = array('time' => $death['date'], 'description' => $description . '.');
} }
} }
} else { } else if ($db->hasColumn('player_deaths', 'time') && $db->hasColumn('player_deaths', 'level') && $db->hasColumn('player_deaths', 'killed_by') && $db->hasColumn('player_deaths', 'is_player')) {
$mostdamage = ''; $mostdamage = '';
if($db->hasColumn('player_deaths', 'mostdamage_by')) if($db->hasColumn('player_deaths', 'mostdamage_by'))
$mostdamage = ', `mostdamage_by`, `mostdamage_is_player`, `unjustified`, `mostdamage_unjustified`'; $mostdamage = ', `mostdamage_by`, `mostdamage_is_player`, `unjustified`, `mostdamage_unjustified`';