mirror of
https://github.com/nsnail/FreeSql.git
synced 2025-06-18 20:08:15 +08:00
- 修复 聚合根仓储 InsertOrUpdate 重复插入的 bug;
This commit is contained in:
@ -165,7 +165,7 @@ namespace FreeSql
|
||||
if (flagExists == true)
|
||||
{
|
||||
var affrows = await UpdateAsync(entity, cancellationToken);
|
||||
if (affrows > 0) return entity;
|
||||
return entity;
|
||||
}
|
||||
if (table.Primarys.Where(a => a.Attribute.IsIdentity).Count() == table.Primarys.Length)
|
||||
{
|
||||
|
@ -218,7 +218,7 @@ namespace FreeSql
|
||||
if (flagExists == true)
|
||||
{
|
||||
var affrows = Update(entity);
|
||||
if (affrows > 0) return entity;
|
||||
return entity;
|
||||
}
|
||||
if (table.Primarys.Where(a => a.Attribute.IsIdentity).Count() == table.Primarys.Length)
|
||||
{
|
||||
|
Reference in New Issue
Block a user