summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorEvan Prodromou <evan@status.net>2010-01-01 11:20:25 -1000
committerEvan Prodromou <evan@status.net>2010-01-01 11:20:25 -1000
commita9d835920824c48caef2a66686d6605ff54586b3 (patch)
treee8c9e297d46d36a5e3a3b3d47bbd51865e6123bf /lib
parent053b8c600d7db73ec19e5f1d3e26c4c98fdf3d8c (diff)
parentb0527801d9c2b84408bbfdf82bbdc5b778f72cfc (diff)
Merge branch 'master' into 0.9.x
Conflicts: classes/Memcached_DataObject.php
Diffstat (limited to 'lib')
-rw-r--r--lib/noticelist.php8
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/noticelist.php b/lib/noticelist.php
index 4c11ceed6..5eb2633ac 100644
--- a/lib/noticelist.php
+++ b/lib/noticelist.php
@@ -191,6 +191,14 @@ class NoticeListItem extends Widget
function show()
{
+ if (empty($this->notice)) {
+ common_log(LOG_WARNING, "Trying to show missing notice; skipping.");
+ return;
+ } else if (empty($this->profile)) {
+ common_log(LOG_WARNING, "Trying to show missing profile (" . $this->notice->profile_id . "); skipping.");
+ return;
+ }
+
$this->showStart();
if (Event::handle('StartShowNoticeItem', array($this))) {
$this->showNotice();