mirror of
https://github.com/dotnetcore/FreeSql.git
synced 2026-02-07 08:50:52 +08:00
Merge pull request #2082 from coolqingcheng/master
修复数据库无法连接的时候,codefirst的HasData会导致SyncStructure迁移死循环调用,然后Stackoverflow异常
This commit is contained in:
@@ -340,6 +340,7 @@ namespace FreeSql.Extensions.EfCoreFluentApi
|
||||
var sdCopyLock = new object();
|
||||
_fsql.Aop.SyncStructureAfter += new EventHandler<Aop.SyncStructureAfterEventArgs>((s, e) =>
|
||||
{
|
||||
if (e.Exception != null) return;
|
||||
object[] sd = null;
|
||||
lock (sdCopyLock)
|
||||
sd = sdCopy?.ToArray();
|
||||
|
||||
Reference in New Issue
Block a user