Exemplo n.º 1
0
        private void Log(string message, string latestString, LogType type, Exception exception)
        {
            var error = new LoggerEntity
            {
                Exception = exception?.Message,
                LogString = latestString,
                Message   = message,
                Time      = $"{DateTime.Now:HH-mm:dd-MM-yyyy}",
                Type      = type.ToString()
            };

            _errorLogRepository.Log(error);
        }
    }
Exemplo n.º 2
0
 public void Log(ErrorLog errorLog)
 {
     errorLogRepository.Log(errorLog);
 }