DEV Community

Discussion on: Flutter Firebase Authentication: Apple Sign In

Collapse
 
morteza_kolivand_4c554f06 profile image
Morteza Kolivand

Hi ,I could not run the code
For solutions, see dart.dev/go/unsound-null-safety
lib/authentication_provider.dart:37:16: Error: A non-null value must be returned since the return type 'User' doesn't allow null.
- 'User' is from 'package:firebase_auth/firebase_auth.dart' ('../../../../Developer/flutter/.pub-cache/hosted/pub.dartlang.org/firebase_auth-0.20.1/lib/firebase_auth.dart').
Future signInWithApple() async {
^
Failed to package /Users/mortezakolivand/Desktop/Flutter Projects/AppleIdTest/appleidtest.
Command PhaseScriptExecution failed with a nonzero exit code
note: Using new build system
note: Building targets in parallel
note: Planning build
note: Analyzing workspace
note: Constructing build description
note: Build preparation complete
Could not build the application for the simulator.
Error launching application on iPhone 12.

I have this error