From 9d9526c5d1c93682e5d21ee2d7d66b172522423e Mon Sep 17 00:00:00 2001 From: aunsane Date: Sun, 11 Mar 2018 23:20:53 +0300 Subject: CloudFile: fix OneDrive token refresh --- plugins/CloudFile/src/Services/microsoft_service.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'plugins/CloudFile/src/Services/microsoft_service.cpp') diff --git a/plugins/CloudFile/src/Services/microsoft_service.cpp b/plugins/CloudFile/src/Services/microsoft_service.cpp index af4ebe2439..4fe9066c22 100644 --- a/plugins/CloudFile/src/Services/microsoft_service.cpp +++ b/plugins/CloudFile/src/Services/microsoft_service.cpp @@ -37,15 +37,14 @@ bool COneDriveService::IsLoggedIn() if (!token || token[0] == 0) return false; time_t now = time(nullptr); - time_t expiresIn = getWord("ExpiresIn"); + time_t expiresIn = getDword("ExpiresIn"); return now < expiresIn; } void COneDriveService::Login() { - ptrA token(getStringA("TokenSecret")); ptrA refreshToken(getStringA("RefreshToken")); - if (token && refreshToken && refreshToken[0]) { + if (refreshToken && refreshToken[0]) { OneDriveAPI::RefreshTokenRequest request(refreshToken); NLHR_PTR response(request.Send(m_hConnection)); -- cgit v1.2.3