diff options
| author | Tim Almdal <tnalmdal@shaw.ca> | 2010-02-10 17:48:39 -0800 |
|---|---|---|
| committer | Tim Almdal <tnalmdal@shaw.ca> | 2010-02-10 17:48:39 -0800 |
| commit | a893b0317d5489552c4c001901ff246e0ec5af1d (patch) | |
| tree | 2599d66bf3dfd205d7b6fbb56c19b634c267a335 /modules/gallery/controllers/photos.php | |
| parent | b42c736607591f8e2bed4aea474ad622b3f7445a (diff) | |
| parent | 8ef08d20883d9b9aa0b7560ce3bf6da8a6632149 (diff) | |
Merge branch 'master' into talmdal_dev
Diffstat (limited to 'modules/gallery/controllers/photos.php')
| -rw-r--r-- | modules/gallery/controllers/photos.php | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/modules/gallery/controllers/photos.php b/modules/gallery/controllers/photos.php index b5da3884..778e9ae7 100644 --- a/modules/gallery/controllers/photos.php +++ b/modules/gallery/controllers/photos.php @@ -24,7 +24,11 @@ class Photos_Controller extends Items_Controller { // sure that we're actually receiving an object Kohana::show_404(); } - access::required("view", $photo); + + if (!access::can("view", $photo)) { + print auth::require_login(); + return; + } $where = array(array("type", "!=", "album")); $position = $photo->parent()->get_position($photo, $where); |
