public void Create(T item)
 {
     using (var db = new FirebirdDb())
     {
         db.Insert(item);
     }
 }
Beispiel #2
0
        public StatusCodeResult Post(User user)
        {
            try
            {
                using (var db = new FirebirdDb())
                {
                    db.Insert(user);
                }

                return(new StatusCodeResult(StatusCodes.Status201Created));
            }
            catch
            {
                return(new StatusCodeResult(StatusCodes.Status205ResetContent));
            }
        }