Skip to content

Commit

Permalink
Warning Fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
mrtwidget committed Jul 16, 2017
1 parent c08ad22 commit 47f29f7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions DatabaseManager.cs
Original file line number Diff line number Diff line change
Expand Up @@ -316,7 +316,7 @@ public void UpdatePlayer(UnturnedPlayer player)
MySQLCommand.Parameters.AddWithValue("@CSteamID", player.CSteamID.ToString());
MySQLCommand.Parameters.AddWithValue("@character_name", player.CharacterName);
MySQLCommand.Parameters.AddWithValue("@display_name", player.DisplayName);
MySQLCommand.Parameters.AddWithValue("@steam_group_id", (player.SteamGroupID != null ? player.SteamGroupID.ToString() : "0"));
MySQLCommand.Parameters.AddWithValue("@steam_group_id", (player.SteamGroupID.ToString() != null ? player.SteamGroupID.ToString() : "0"));
MySQLCommand.Parameters.AddWithValue("@steam_avatar_medium", (player.SteamProfile.AvatarMedium != null ? player.SteamProfile.AvatarMedium.ToString() : Livemap.Instance.Configuration.Instance.PlayerDefaultSteamAvatar));
MySQLCommand.Parameters.AddWithValue("@server_id", Provider.serverID);
MySQLCommand.Parameters.AddWithValue("@ip_address", player.IP.ToString());
Expand Down Expand Up @@ -501,7 +501,7 @@ public void OnPlayerConnected(UnturnedPlayer player)
// update player connection time
MySqlCommand MySQLCommand = MySQLConnection.CreateCommand();
MySQLCommand.CommandText = "UPDATE " + Livemap.Instance.Configuration.Instance.DatabaseTableLivemapData + " SET last_connect = NULL WHERE CSteamID = '" + player.CSteamID.ToString() + "'";
object result = MySQLCommand.ExecuteScalar();
MySQLCommand.ExecuteScalar();
}
catch (Exception ex)
{
Expand Down

0 comments on commit 47f29f7

Please sign in to comment.