This commit is contained in:
parent
8f665394ff
commit
3aec0399d0
|
@ -1,8 +1,8 @@
|
|||
:start
|
||||
::定义版本
|
||||
set EFCORE2=2.2.0.20
|
||||
set EFCORE3=3.2.0.20
|
||||
set EFCORE5=5.2.0.20
|
||||
set EFCORE2=2.2.0.21
|
||||
set EFCORE3=3.2.0.21
|
||||
set EFCORE5=5.2.0.21
|
||||
|
||||
::删除所有bin与obj下的文件
|
||||
@echo off
|
||||
|
|
|
@ -109,10 +109,11 @@ namespace ShardingCore.Sharding.Enumerators
|
|||
#if EFCORE2
|
||||
public void Dispose()
|
||||
{
|
||||
_asyncSource.Dispose();
|
||||
_asyncSource?.Dispose();
|
||||
_syncSource?.Dispose();
|
||||
}
|
||||
|
||||
public async Task<bool> MoveNext(CancellationToken cancellationToken=new CancellationToken())
|
||||
public async Task<bool> MoveNext(CancellationToken cancellationToken = new CancellationToken())
|
||||
{
|
||||
if (skip)
|
||||
{
|
||||
|
@ -134,8 +135,13 @@ namespace ShardingCore.Sharding.Enumerators
|
|||
{
|
||||
if (tryGetCurrentError)
|
||||
return default;
|
||||
return _asyncSource.Current;
|
||||
}catch(Exception e)
|
||||
if (_asyncSource!= null)
|
||||
return _asyncSource.Current;
|
||||
if (_syncSource != null)
|
||||
return _syncSource.Current;
|
||||
return default;
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
tryGetCurrentError = true;
|
||||
return default;
|
||||
|
|
Loading…
Reference in New Issue