From a84409336532e4b3776b6a747aa845bd74615d11 Mon Sep 17 00:00:00 2001 From: Zach Prezkuta Date: Mon, 30 Apr 2012 20:51:22 -0600 Subject: [PATCH] change api.php in function api_item_get_user to check if $usercache is NULL before checking an element in it --- include/api.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/api.php b/include/api.php index f9be68c3df..a693a32c8b 100644 --- a/include/api.php +++ b/include/api.php @@ -380,7 +380,7 @@ $nick = $name; // Generating a random ID - if (!array_key_exists($nick, $usercache)) + if (is_null($usercache[$nick]) or !array_key_exists($nick, $usercache)) $usercache[$nick] = mt_rand(2000000, 2100000); $ret = array( -- 2.39.5