Fixed broken ProbMethod in Entity/Index, fixed undisposed MySQL connections, dependency update, improved logging, improved cache invalidation
This commit is contained in:
@@ -3,7 +3,7 @@ using MySql.Data.MySqlClient;
|
||||
|
||||
namespace Server;
|
||||
|
||||
public class SQLHelper
|
||||
public class SQLHelper:IDisposable
|
||||
{
|
||||
public MySqlConnection connection;
|
||||
public string connectionString;
|
||||
@@ -19,6 +19,12 @@ public class SQLHelper
|
||||
return new SQLHelper(newConnection, connectionString);
|
||||
}
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
connection.Close();
|
||||
GC.SuppressFinalize(this);
|
||||
}
|
||||
|
||||
public DbDataReader ExecuteSQLCommand(string query, Dictionary<string, dynamic> parameters)
|
||||
{
|
||||
lock (connection)
|
||||
|
||||
Reference in New Issue
Block a user