aboutsummaryrefslogtreecommitdiff
path: root/engine
diff options
context:
space:
mode:
authorben <ben@36083f99-b078-4883-b0ff-0f9b5a30f544>2009-03-04 18:09:31 +0000
committerben <ben@36083f99-b078-4883-b0ff-0f9b5a30f544>2009-03-04 18:09:31 +0000
commit0f97c0d4c48ed779c985d9ac4288db65c127234c (patch)
tree97ec4acdbdb246a838361915fc4f7a6cbb693d5b /engine
parent899d26f54d8a89ecb036bf680b54d14d710fdbdc (diff)
downloadelgg-0f97c0d4c48ed779c985d9ac4288db65c127234c.tar.gz
elgg-0f97c0d4c48ed779c985d9ac4288db65c127234c.tar.bz2
Stopgap for when you can no longer view river items.
git-svn-id: https://code.elgg.org/elgg/trunk@3082 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'engine')
-rw-r--r--engine/lib/river2.php13
1 files changed, 9 insertions, 4 deletions
diff --git a/engine/lib/river2.php b/engine/lib/river2.php
index a08e29dc8..9d62d88f7 100644
--- a/engine/lib/river2.php
+++ b/engine/lib/river2.php
@@ -210,10 +210,15 @@
function elgg_view_river_item($item) {
if (isset($item->view)) {
- if (elgg_view_exists($item->view)) {
- $body = elgg_view($item->view,array(
- 'item' => $item
- ));
+ $object = get_entity($item->object_guid);
+ if (!$object) {
+ $body = elgg_view('river/item/noaccess');
+ } else {
+ if (elgg_view_exists($item->view)) {
+ $body = elgg_view($item->view,array(
+ 'item' => $item
+ ));
+ }
}
return elgg_view('river/item/wrapper',array(
'item' => $item,