diff options
author | Azul <azul@leap.se> | 2013-11-06 11:26:46 +0100 |
---|---|---|
committer | Azul <azul@leap.se> | 2013-11-06 11:30:33 +0100 |
commit | 24598b5c5e4df20c423ec74ea8e9df1592483c6b (patch) | |
tree | 08697724628ae443599c3c745c11757e75b40d12 /users/test/functional | |
parent | ebc60f3aba1ca08e454ba5e91f49905df2e5fa13 (diff) |
destroy all tickets created by a user when account is destroyed
In order to keep the users engine independent of the tickets engine i added a generic load hook to the account model. The tickets engine then monkeypatches the account destruction and destroys all tickets before the user is destroyed.
The tickets are destroyed first so that even if things break there should never be tickets with an outdated user id.
I would have prefered to use super over using an alias_method_chain but I have not been able to figure out a way to make account a superclass of the account extension and still refer to Account from the users engine.
Diffstat (limited to 'users/test/functional')
0 files changed, 0 insertions, 0 deletions