private void InsertLog(LogEntity data, bool isError = false) { try { var collection = mongoFactory.InsertOne((isError) ? AppConfigHelper.GetMongoInfo().ErrorLogCollection : AppConfigHelper.GetMongoInfo().InfoLogCollection, data); } catch { throw new KnownException(ErrorTypeEnum.DbOperationException, "LogFactory", ExceptionMessageHelper.UnexpectedLogError); } }