aboutsummaryrefslogtreecommitdiff
path: root/upload.php
diff options
context:
space:
mode:
Diffstat (limited to 'upload.php')
-rw-r--r--upload.php36
1 files changed, 18 insertions, 18 deletions
diff --git a/upload.php b/upload.php
index 062fec325..dda327ef8 100644
--- a/upload.php
+++ b/upload.php
@@ -10,26 +10,26 @@
// Get the current page's owner
- if ($album = (int) get_input('container_guid'))
- {
- $album_entity = get_entity($album);
-
- //if album does not exist or user does not have access
- if(!$album_entity || !$album_entity->canEdit())
- forward('pg/photos/owned/');
-
- //set group to "real" container
- $container = $album_entity->container_guid;
- set_page_owner($container);
- }
- else
+ if ($album = (int) get_input('container_guid'))
+ {
+ $album_entity = get_entity($album);
+
+ //if album does not exist or user does not have access
+ if(!$album_entity || !$album_entity->canEdit())
forward('pg/photos/owned/');
+
+ //set group to "real" container
+ $container = $album_entity->container_guid;
+ set_page_owner($container);
+ }
+ else
+ forward('pg/photos/owned/');
- $page_owner = page_owner_entity();
- if ($page_owner === false || is_null($page_owner)) {
- $page_owner = $_SESSION['user'];
- set_page_owner($page_owner->getGUID());
- }
+ $page_owner = page_owner_entity();
+ if ($page_owner === false || is_null($page_owner)) {
+ $page_owner = $_SESSION['user'];
+ set_page_owner($page_owner->getGUID());
+ }
set_context('photos');
$title = elgg_echo('album:addpix') . ' ' . $album_entity->title;