Browse Source

[Logs] Added automatic log for user visible errors

develop
Robin Thoni 9 years ago
parent
commit
72437a8d9c
1 changed files with 2 additions and 0 deletions
  1. 2
    0
      WebApiUtils/BusinessManager/BMRHandler.cs

+ 2
- 0
WebApiUtils/BusinessManager/BMRHandler.cs View File

1
 using System.Net;
1
 using System.Net;
2
 using System.Net.Http;
2
 using System.Net.Http;
3
 using System.Web.Http;
3
 using System.Web.Http;
4
+using iiie.Logs.DataAccess;
4
 using iiie.Logs.DBO;
5
 using iiie.Logs.DBO;
5
 
6
 
6
 namespace iiie.WebApiUtils.BusinessManager
7
 namespace iiie.WebApiUtils.BusinessManager
61
         {
62
         {
62
             if (result.Status == ResultStatus.Success)
63
             if (result.Status == ResultStatus.Success)
63
                 return result.Data;
64
                 return result.Data;
65
+            result.Log();
64
             var msg = request.CreateErrorResponse(ResultStatusToHttp(result.Status), OpResultToString(result));
66
             var msg = request.CreateErrorResponse(ResultStatusToHttp(result.Status), OpResultToString(result));
65
             throw new HttpResponseException(msg);
67
             throw new HttpResponseException(msg);
66
         }
68
         }

Loading…
Cancel
Save