Ejemplo n.º 1
0
        public IEnumerable <News> Get()
        {
            logger.Info("start News: ");
            List <News> List = new List <News>();

            try
            {
                List = context.AllNews().ToList();
                logger.Info("End  News: ");
                return(List);
            }
            catch (Exception ex)
            {
                logger.Error("Error in News " + ex.Message);
                logger.Info("End  News: ");
                return(null);
            }
        }