修复可能的异步等待问题

This commit is contained in:
陈梓阳 2024-01-17 17:05:03 +08:00
parent dda87349fd
commit f4f7ff316b
2 changed files with 2 additions and 2 deletions

View File

@ -57,7 +57,7 @@ public class TransformService : ITransformService
//修改record
_options.Value.RecordModify?.Invoke(record);
//缓存record
_options.Value.RecordCache?.Invoke(record, _cache);
await _options.Value.RecordCache?.Invoke(record, _cache);
//替换record
var replaceRecord =await _options.Value.RecordReplace?.Invoke(record, _cache);
if (replaceRecord != null)

View File

@ -20,7 +20,7 @@ public class DataTransformOptions
public Action<DataRecord>? RecordModify { get; set; }//数据修改
public Func<DataRecord, IDistributedCache, Task<DataRecord?>>? RecordReplace { get; set; }//数据替换
public Func<DataRecord, IList<DataRecord>?>? RecordAdd { get; set; }//数据替换
public Action<DataRecord, IDistributedCache>? RecordCache { get; set; }//数据缓存
public Func<DataRecord, IDistributedCache, Task>? RecordCache { get; set; }//数据缓存
/// <summary>
/// 配置导入数据的特殊列