From 3cddf405127074ddf29cdd681c3197ab6a558617 Mon Sep 17 00:00:00 2001 From: trogwar Date: Thu, 21 Jul 2016 05:59:30 +0300 Subject: [PATCH] Fallback that will prevent causing errors in 4.x version of VK API --- src/Vkontakte.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/Vkontakte.php b/src/Vkontakte.php index 68a0d05..b789903 100644 --- a/src/Vkontakte.php +++ b/src/Vkontakte.php @@ -171,6 +171,9 @@ class Vkontakte extends AbstractProvider if (!empty($additional['email'])) { $response['email'] = $additional['email']; } + if (!empty($response['uid']) && 4 === floor($this->version)) { + $response['id'] = $response['uid']; + } if (!empty($additional['user_id'])) { $response['id'] = $additional['user_id']; }