]> git.mxchange.org Git - quix0rs-gnu-social.git/commitdiff
defaultDesign was undefined; fixed that
authorEvan Prodromou <evan@status.net>
Sun, 10 Jan 2010 22:10:31 +0000 (14:10 -0800)
committerEvan Prodromou <evan@status.net>
Sun, 10 Jan 2010 22:10:31 +0000 (14:10 -0800)
lib/api.php

index 4ed49e45293197f790d167f9a8da24e882ce4b98..06d7c079d2e255a53ec808e18df375c93a50a368 100644 (file)
@@ -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);