Browse Source

Moved scheduler script before CommitChanges

Kenric Nugteren 2 years ago
parent
commit
99c969c2a0
1 changed files with 1 additions and 2 deletions
  1. 1 2
      InABox.Database/Stores/Store.cs

+ 1 - 2
InABox.Database/Stores/Store.cs

@@ -599,11 +599,10 @@ namespace InABox.Database
 
             //UpdateExternalLinks(entity, false);
 
+            entity = RunScript(ScriptType.AfterSave, new[] { entity }).First();
             entity.CommitChanges();
 
             //CloseSession("Save", false);
-
-            entity = RunScript(ScriptType.AfterSave, new[] { entity }).First();
             //}
             //catch (Exception e)
             //{