]> git.mxchange.org Git - friendica.git/commitdiff
change api.php in function api_item_get_user to check if $usercache is NULL before...
authorZach Prezkuta <fermion@gmx.com>
Tue, 1 May 2012 02:51:22 +0000 (20:51 -0600)
committerZach Prezkuta <fermion@gmx.com>
Tue, 1 May 2012 02:51:22 +0000 (20:51 -0600)
include/api.php

index f9be68c3df3a4961c3d9e6a98b6c7fe1337c9f80..a693a32c8bb3c797a4d20afa62493ed3d4bf2ce2 100644 (file)
                        $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(