public bool DeleteUser(int id) { try { Log.Information("File Name: " + _stackFrame.GetMethod().DeclaringType.Name + ".cs " + "NameSpace: " + _stackFrame.GetMethod().DeclaringType.Namespace + " Method Name: DeleteUser() "); bool success = false; if (id != 0) { success = _userRepository.DeleteUser(id); } Log.Information("File Name: " + _stackFrame.GetMethod().DeclaringType.Name + ".cs " + "DeleteUser() Method Executed Successfully"); return(success); } catch (Exception ex) { Log.Error("Error Message: " + ex.Message + " " + ex.StackTrace); throw; } }