Amazon CognitoUserPool getUser Exception -
i created user pool object follow:
cognitouserpool userpool= new cognitouserpool(context, userpoolid, clientid, clientsecret, cipclient);
with object , valid user name, can create cognito user follow:
cognitouser user = userpool.getuser(username);
this works fine, , can data transfer , on. after few days, got exception:
java.lang.nullpointerexception: attempt invoke virtual method 'com.amazonaws.mobileconnectors.cognitoidentityprovider.cognitouser com.amazonaws.mobileconnectors.cognitoidentityprovider.cognitouserpool.getuser(java.lang.string)' on null object reference
can 1 explain me why got exception , how fix it.
note: never release cognitouserpool object. don't understand why have null object reference!
Comments
Post a Comment