diff options
| author | mo khan <mo@mokhan.ca> | 2014-07-01 22:49:41 -0600 |
|---|---|---|
| committer | mo khan <mo@mokhan.ca> | 2014-07-01 22:49:41 -0600 |
| commit | 4948cd5317b3b3bc578aeafae80c835cd8780a2d (patch) | |
| tree | f8fe6120c364c62f4d4262794634137fff675226 /app/controllers/api/v1 | |
| parent | a5db20d0bad654ef25651eeb3a30ea64ce8c78d3 (diff) | |
render json of deleted cake.
Diffstat (limited to 'app/controllers/api/v1')
| -rw-r--r-- | app/controllers/api/v1/cakes_controller.rb | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/app/controllers/api/v1/cakes_controller.rb b/app/controllers/api/v1/cakes_controller.rb index 62b9187b..c8241b6c 100644 --- a/app/controllers/api/v1/cakes_controller.rb +++ b/app/controllers/api/v1/cakes_controller.rb @@ -36,8 +36,9 @@ module Api end def destroy - current_user.creations.find(params[:id]).destroy! - render nothing: true + @cake = current_user.creations.find(params[:id]) + @cake.destroy! + respond_with(@cake) end private |
