madeon (madeon) wrote in changelog,
madeon
madeon
changelog

[ljcom] r11788: LJSUP-11858: Vkontakte integration

Committer: sbelyaev
LJSUP-11858: Vkontakte integration
U   trunk/cgi-bin/LJ/Identity/Vkontakte.pm
Modified: trunk/cgi-bin/LJ/Identity/Vkontakte.pm
===================================================================
--- trunk/cgi-bin/LJ/Identity/Vkontakte.pm	2012-04-25 09:19:28 UTC (rev 11787)
+++ trunk/cgi-bin/LJ/Identity/Vkontakte.pm	2012-04-25 09:32:33 UTC (rev 11788)
@@ -54,7 +54,12 @@
             'access_token' => $token,
         } );
 
-        $userdata = (ref $res eq 'ARRAY') ? $res->[0] : $res;
+        $userdata = $res;
+        if ($res->{'response'}) {
+            $userdata = $res->{'response'};
+        }
+
+        $userdata = $userdata->[0];
     }
 
     ## INITIALIZE USER PROFILE

Tags: ljcom, madeon, pm, sbelyaev
Subscribe
  • Post a new comment

    Error

    Anonymous comments are disabled in this journal

    default userpic

    Your reply will be screened

    Your IP address will be recorded 

  • 0 comments