예제 #1
0
        public async Task <IActionResult> UnregisterActivity(int id)
        {
            var user = await GetCurrentUserAsync();

            var signedUp = _prepOpsDataAccess.GetActivitySignup(id, user.Id);

            if (signedUp == null)
            {
                return(HttpNotFound());
            }
            _prepOpsDataAccess.DeleteActivitySignup(signedUp.Id);
            return(new HttpStatusCodeResult((int)HttpStatusCode.OK));
        }