summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBharat Mediratta <bharat@menalto.com>2009-05-03 21:14:18 +0000
committerBharat Mediratta <bharat@menalto.com>2009-05-03 21:14:18 +0000
commita676ac8e60dc93de5b18e649588594a37180b717 (patch)
tree09ff5447b6e4f4036f13c5ed2c4a36723ebc8112
parente70be4c0c2d150c20a73b1e53ce5408575574ec2 (diff)
Don't try to make a new photo the album cover unless we can edit the parent album
-rw-r--r--core/helpers/photo.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/core/helpers/photo.php b/core/helpers/photo.php
index c086393e..5cf8a075 100644
--- a/core/helpers/photo.php
+++ b/core/helpers/photo.php
@@ -97,7 +97,7 @@ class photo_Core {
graphics::generate($photo);
// If the parent has no cover item, make this it.
- if ($parent->album_cover_item_id == null) {
+ if (access::can("edit", $parent) && $parent->album_cover_item_id == null) {
item::make_album_cover($photo);
}