AshEvents.DestroyActionWrapper (ash_events v0.6.0)

Copy Markdown View Source

Wrapper for destroy actions that enables event tracking.

This module handles both hard and soft deletes. Soft deletes (actions with soft?: true) are implemented by Ash as updates under the hood, so this module implements both destroy/3 for hard deletes and update/3 for soft deletes.

Summary

Functions

Handles hard destroy actions.

Handles soft destroy actions (where soft?: true).

Functions

destroy(changeset, module_opts, ctx)

Handles hard destroy actions.

update(changeset, module_opts, ctx)

Handles soft destroy actions (where soft?: true).

Ash implements soft deletes as updates, so it calls update/3 on the manual module.