Update tracking diff

This commit is contained in:
sunkaixuan
2023-09-02 13:45:43 +08:00
parent ee0f981695
commit e561d30c75

View File

@@ -600,7 +600,7 @@ namespace SqlSugar
} }
private void After(string sql) private void After(string sql)
{ {
if (this.IsEnableDiffLogEvent) if (this.IsEnableDiffLogEvent && !string.IsNullOrEmpty(sql))
{ {
var isDisableMasterSlaveSeparation = this.Ado.IsDisableMasterSlaveSeparation; var isDisableMasterSlaveSeparation = this.Ado.IsDisableMasterSlaveSeparation;
this.Ado.IsDisableMasterSlaveSeparation = true; this.Ado.IsDisableMasterSlaveSeparation = true;
@@ -650,7 +650,7 @@ namespace SqlSugar
} }
private void Before(string sql) private void Before(string sql)
{ {
if (this.IsEnableDiffLogEvent) if (this.IsEnableDiffLogEvent&&!string.IsNullOrEmpty(sql))
{ {
var isDisableMasterSlaveSeparation = this.Ado.IsDisableMasterSlaveSeparation; var isDisableMasterSlaveSeparation = this.Ado.IsDisableMasterSlaveSeparation;
this.Ado.IsDisableMasterSlaveSeparation = true; this.Ado.IsDisableMasterSlaveSeparation = true;