Skip to content

Commit ae85d41

Browse files
author
Oleg Smirnov
committed
#392, #390 fix NumberFormatException
1 parent 3052da2 commit ae85d41

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

dependencies.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
ext.sdkVersions = [
22
code : '10',
3-
name : '2.0.0',
3+
name : '2.0.1',
44

55
minSdk : 16,
66
targetSdk : 26,

vk-sdk-core/src/main/java/com/vk/api/sdk/auth/VKAuthManager.kt

+2-1
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ internal class VKAuthManager {
9999
else -> return null
100100
}
101101

102-
return if (tokenParams != null) VKAuthResult(VKAccessToken(tokenParams)) else null
102+
return if (tokenParams != null && tokenParams[VK_AUTH_ERROR] == null) VKAuthResult(VKAccessToken(tokenParams)) else null
103103
}
104104

105105

@@ -123,6 +123,7 @@ internal class VKAuthManager {
123123
private const val VK_APP_PACKAGE_ID = "com.vkontakte.android"
124124
private const val VK_APP_AUTH_ACTION = "com.vkontakte.android.action.SDK_AUTH"
125125
const val VK_EXTRA_TOKEN_DATA = "extra-token-data"
126+
const val VK_AUTH_ERROR = "error"
126127

127128
private const val PREFERENCE_NAME = "com.vkontakte.android_pref_name"
128129

0 commit comments

Comments
 (0)