We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 2198e29 commit 6aa44c8Copy full SHA for 6aa44c8
guides/concepts/resources.md
@@ -1476,13 +1476,16 @@ class PostResource < ApplicationResource
1476
# By default, we'd call adapter.save(model_instance)
1477
def save(model_instance)
1478
model_instance.save
1479
+ model_instance
1480
end
1481
1482
+
1483
# This is an *override*
1484
# During #destroy, actually save the model instance
1485
# By default, we'd call adapter.destroy(model_instance)
1486
def delete(model_instance)
- model.destroy
1487
+ model_instance.destroy
1488
1489
1490
1491
# Finally, you may want to hook around *all* the above steps:
0 commit comments