'List<Object?>' is not a subtype of type 'PigeonUserDetails?'

codarbind

ADEKOLA Abdwahab

Posted on September 23, 2024

'List<Object?>' is not a subtype of type 'PigeonUserDetails?'

After I rebuilt my project to resolve an issue with a @freezed class my Google login feature started throwing errors.

'List<Object?>' is not a subtype of type 'PigeonUserDetails?'
Enter fullscreen mode Exit fullscreen mode

I saw the issue on github, sadly the solution provided there did not work.

Doing some debugprints helped a bit but I could not see the status of the line that is failing after the last debugprint, hence I opted for the debugger, and then placed some breaking points.

I realized that there was no signInWithCredential method but there was currentUser which had the details of the logging-in user

//before
 UserCredential result = await auth.signInWithCredential(authCredential);

//after
 User? result =  auth.currentUser;//signInWithCredential(authCredential);
Enter fullscreen mode Exit fullscreen mode
💖 💪 🙅 🚩
codarbind
ADEKOLA Abdwahab

Posted on September 23, 2024

Join Our Newsletter. No Spam, Only the good stuff.

Sign up to receive the latest update from our blog.

Related