コード例 #1
0
        public async Task <ActionResult <string> > DeleteKeep(int id)
        {
            try
            {
                Profile userInfo = await HttpContext.GetUserInfoAsync <Profile>();

                return(Ok(_ks.DeleteKeep(id, userInfo.Id)));
            }
            catch (System.Exception error)
            {
                return(BadRequest(error.Message));
            }
        }
コード例 #2
0
ファイル: KeepsController.cs プロジェクト: JakeCarp/keepr
        public async Task <ActionResult <String> > DeleteKeep(int id)
        {
            try
            {
                var userInfo = await HttpContext.GetUserInfoAsync <Account>();

                String res = _ks.DeleteKeep(userInfo.Id, id);
                return(Ok(res));
            }
            catch (Exception e)
            {
                return(BadRequest(e.Message));
            }
        }