diff options
author | Bharat Mediratta <bharat@menalto.com> | 2009-07-16 12:29:16 -0700 |
---|---|---|
committer | Bharat Mediratta <bharat@menalto.com> | 2009-07-16 12:31:40 -0700 |
commit | 0f766b149d0cee7af664f2321fddc6f04cda70ac (patch) | |
tree | 51d8cd4e26df82955d57eefaa46349568d054126 /modules/gallery/helpers/movie.php | |
parent | 43324fd12a23b35707300ff110f207552c3811f1 (diff) |
Second non-trivial change to the event code. We now publish model
related events from within the model handling code. The only
exception to this currently is item_created which is challenging
because we have to save the item using ORM_MPTT::add_to_parent()
before the object itself is fully set up. When we get that down to
one call to save() we can publish that event from within the model
also.
Diffstat (limited to 'modules/gallery/helpers/movie.php')
-rw-r--r-- | modules/gallery/helpers/movie.php | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/modules/gallery/helpers/movie.php b/modules/gallery/helpers/movie.php index d62ead76..4f4169d5 100644 --- a/modules/gallery/helpers/movie.php +++ b/modules/gallery/helpers/movie.php @@ -102,6 +102,8 @@ class movie_Core { copy($filename, $movie->file_path()); + // @todo: publish this from inside Item_Model::save() when we refactor to the point where + // there's only one save() happening here. module::event("item_created", $movie); // Build our thumbnail |