Skip to content

Commit

Permalink
Added ability to run module hooks for assets module
Browse files Browse the repository at this point in the history
  • Loading branch information
David McReynolds committed Sep 30, 2014
1 parent c97ea1d commit ac21f57
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions fuel/modules/fuel/controllers/assets.php
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,12 @@ public function create($dir = NULL, $inline = FALSE)
$redirect_to = uri_safe_decode($this->input->get_post('redirect_to'));
$id = $posted['file_name'];

// run before_create hook
$this->_run_hook('before_create', $posted);

// run before_save hook
$this->_run_hook('before_save', $posted);

if ($this->fuel->assets->upload($posted))
{
foreach($_FILES as $filename => $fileinfo)
Expand Down

0 comments on commit ac21f57

Please sign in to comment.