diff options
author | Pablo Martin <caedes@sindominio.net> | 2012-11-05 08:16:07 +0000 |
---|---|---|
committer | root <root@ops.vz.lan> | 2012-11-05 08:16:18 +0000 |
commit | 931b5803ec26a8169870124b0027a5ccf9e3200e (patch) | |
tree | f4b9e13bc804357967ec4b18f1daf1317555bda6 /start.php | |
parent | af8e7c0340839db0d24b7d6fc61899d950ea341f (diff) | |
download | elgg-931b5803ec26a8169870124b0027a5ccf9e3200e.tar.gz elgg-931b5803ec26a8169870124b0027a5ccf9e3200e.tar.bz2 |
avoid some errors and some backwards compatibility.
Diffstat (limited to 'start.php')
-rw-r--r-- | start.php | 12 |
1 files changed, 12 insertions, 0 deletions
@@ -120,6 +120,15 @@ function tidypics_page_handler($page) { elgg_load_js('tidypics'); $base = elgg_get_plugins_path() . 'lightpics/pages/photos'; + + // sometimes owner comes as group:181872 which is not automatically handled + if (isset($page[1]) && strpos($page[1], 'group:') === 0) { + $parts = explode(':', $page[1]); + $owner_guid = $parts[1]; + if ($owner_guid) { + elgg_set_page_owner_guid($owner_guid); + } + } switch ($page[0]) { case "all": // all site albums case "world": @@ -128,6 +137,9 @@ function tidypics_page_handler($page) { case "owned": // albums owned by container entity case "owner": + if (!$owner) { + forward(); + } require "$base/owner.php"; break; |