mirror of
https://gh.wpcy.net/https://github.com/discourse/discourse.git
synced 2026-06-19 04:25:50 +08:00
Previously a thread-local "active automation" guard meant that as soon as one automation was running, any nested `trigger!` call was silently skipped. This prevented automations from triggering other automations. This replaces that guard with a per-thread recursion depth counter. Nested triggers are now allowed up to `MAX_RECURSION_DEPTH` (5); going beyond that raises `RecursionLimitExceeded` (recorded via `Stat.log`) to guard against infinite recursion. |
||
|---|---|---|
| .. | ||
| discourse_automation | ||
| scriptable_spec.rb | ||
| triggerable_spec.rb | ||