Commit 4948cd53

mo khan <mo@mokhan.ca>
2014-07-02 04:49:41
render json of deleted cake.
1 parent a5db20d
Changed files (1)
app
controllers
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