Beispiel #1
0
        public Track Delete(Track request)
        {
            //var toDelete = Tracks.AsQueryable().FirstOrDefault(track => track.Id == request.Id);
            Tracks.Remove(Query.EQ("_id", request.Id));

            return request;
        }
Beispiel #2
0
 public Track Put(Track request)
 {
     return null;
 }
Beispiel #3
0
        public Track Post(Track request)
        {
            var insert = Tracks.Insert(request);

            if (!insert.Ok) throw new HttpError(insert.LastErrorMessage);

            return request;
        }