diff options
author | Sarven Capadisli <csarven@status.net> | 2009-11-11 18:47:51 +0000 |
---|---|---|
committer | Sarven Capadisli <csarven@status.net> | 2009-11-11 18:47:51 +0000 |
commit | 6a19bcc0e2e2e0d0743480921e3be787b5b27729 (patch) | |
tree | ced56ff7fd8ff1bcba7d1121ba5cb9a04d0dcfd9 /lib | |
parent | 095cf8ebf1e95dfc2e625ca6a7f705dbf007a9fd (diff) | |
parent | 7f8dbb8e457d1e5534ebb569988d84ee3adaeef7 (diff) |
Merge branch '0.9.x' of git@gitorious.org:statusnet/mainline into 0.9.x
Diffstat (limited to 'lib')
-rw-r--r-- | lib/util.php | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/lib/util.php b/lib/util.php index 81160d052..7aca4af8d 100644 --- a/lib/util.php +++ b/lib/util.php @@ -350,8 +350,11 @@ function common_current_user() common_ensure_session(); $id = isset($_SESSION['userid']) ? $_SESSION['userid'] : false; if ($id) { - $_cur = User::staticGet($id); - return $_cur; + $user = User::staticGet($id); + if ($user) { + $_cur = $user; + return $_cur; + } } } |