aboutsummaryrefslogtreecommitdiff
path: root/juick-www/src/main/java/com/juick/www/controllers
diff options
context:
space:
mode:
Diffstat (limited to 'juick-www/src/main/java/com/juick/www/controllers')
-rw-r--r--juick-www/src/main/java/com/juick/www/controllers/SocialLogin.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/juick-www/src/main/java/com/juick/www/controllers/SocialLogin.java b/juick-www/src/main/java/com/juick/www/controllers/SocialLogin.java
index 674be157..6c9a1827 100644
--- a/juick-www/src/main/java/com/juick/www/controllers/SocialLogin.java
+++ b/juick-www/src/main/java/com/juick/www/controllers/SocialLogin.java
@@ -260,7 +260,7 @@ public class SocialLogin {
.build(VkontakteApi.instance());
OAuth2AccessToken token = vkService.getAccessToken(code);
- OAuthRequest meRequest = new OAuthRequest(Verb.GET, "https://api.vk.com/method/users.get?fields=screen_name");
+ OAuthRequest meRequest = new OAuthRequest(Verb.GET, "https://api.vk.com/method/users.get?fields=screen_name&v=5.73");
vkService.signRequest(token, meRequest);
String graph = vkService.execute(meRequest).getBody();
@@ -273,7 +273,7 @@ public class SocialLogin {
throw new HttpBadRequestException();
}
- Long vkID = NumberUtils.toLong(jsonUser.getUid(), 0);
+ Long vkID = NumberUtils.toLong(jsonUser.getId(), 0);
int uid = crosspostService.getUIDbyVKID(vkID);
if (uid > 0) {
Cookie c = new Cookie("hash", userService.getHashByUID(uid));