From 7aa43f3c93a5434b59a66824b2816d5ba8cf1978 Mon Sep 17 00:00:00 2001 From: Evan Prodromou Date: Sun, 10 Jan 2010 14:10:31 -0800 Subject: [PATCH] defaultDesign was undefined; fixed that --- lib/api.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/api.php b/lib/api.php index 4ed49e4529..06d7c079d2 100644 --- a/lib/api.php +++ b/lib/api.php @@ -140,12 +140,14 @@ class ApiAction extends Action // Note: some profiles don't have an associated user + $defaultDesign = Design::siteDesign(); + if (!empty($user)) { $design = $user->getDesign(); } if (empty($design)) { - $design = Design::siteDesign(); + $design = $defaultDesign; } $color = Design::toWebColor(empty($design->backgroundcolor) ? $defaultDesign->backgroundcolor : $design->backgroundcolor); -- 2.39.5