File tree Expand file tree Collapse file tree 1 file changed +6
-0
lines changed
src/main/java/com/docusign/esign/client/auth Expand file tree Collapse file tree 1 file changed +6
-0
lines changed Original file line number Diff line number Diff line change @@ -85,6 +85,12 @@ public synchronized void updateAccessToken() {
8585 throw new ClientHandlerException (e .getMessage (), e );
8686 }
8787 if (accessTokenResponse != null && accessTokenResponse .getAccessToken () != null ) {
88+ if (accessTokenResponse .getAccessToken () == null ) {
89+ throw new ClientHandlerException ("Error while requesting an access token. No 'access_token' found." );
90+ }
91+ if (accessTokenResponse .getExpiresIn () == null ) {
92+ throw new ClientHandlerException ("Error while requesting an access token. No 'expires_in' found." );
93+ }
8894 setAccessToken (accessTokenResponse .getAccessToken (), accessTokenResponse .getExpiresIn ());
8995 if (accessTokenListener != null ) {
9096 accessTokenListener .notify ((BasicOAuthToken ) accessTokenResponse .getOAuthToken ());
You can’t perform that action at this time.
0 commit comments