mirror of
https://github.com/nsnail/FreeSql.git
synced 2025-06-20 12:58:15 +08:00
@ -54,8 +54,11 @@ namespace FreeSql.Internal.CommonProvider
|
||||
|
||||
public void Return(Object<DbConnection> obj, bool isReset = false)
|
||||
{
|
||||
if (obj == null) return;
|
||||
Policy.OnDestroy(obj.Value);
|
||||
if (obj == null || obj.Value == null) return;
|
||||
if (obj.Value.State != ConnectionState.Closed)
|
||||
obj.Value.Close();
|
||||
if (_dataType == DataType.Sqlite)
|
||||
obj.Dispose();
|
||||
}
|
||||
|
||||
public bool SetUnavailable(Exception exception)
|
||||
|
Reference in New Issue
Block a user