소스 검색

Added Logging to identify cause of Deletion Exceptions

Frank van den Bos 2 년 전
부모
커밋
be2542d397
1개의 변경된 파일3개의 추가작업 그리고 2개의 파일을 삭제
  1. 3 2
      InABox.Database/Stores/Store.cs

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

@@ -778,8 +778,9 @@ namespace InABox.Database
                 }
                 catch (Exception e)
                 {
+                    Logger.Send(LogType.Error, "", $"Error in DoDelete(T entity, string auditnote):\n{CoreUtils.FormatException(e)}");
                     //CloseSession("Delete", true);
-                    throw e;
+                    //throw e;
                 }
                 //CloseSession("Delete",true);
 
@@ -817,8 +818,8 @@ namespace InABox.Database
                 }
                 catch (Exception e)
                 {
+                    Logger.Send(LogType.Error, "", $"Error in DoDelete(IEnumerable<T> entities, string auditnote):\n{CoreUtils.FormatException(e)}");
                     ////CloseSession("Delete", true);
-                    throw e;
                 }
 
                 ////CloseSession("Delete", true);