MCarlomagno / FaceRecognitionAuth

😀🤳 Simple face recognition authentication (Sign up + Sign in) written in Flutter using Tensorflow Lite and Firebase ML vision library.
BSD 3-Clause "New" or "Revised" License
385 stars 193 forks source link

Late Initialization Error in faceDetected #27

Open armaneffendi06 opened 3 years ago

armaneffendi06 commented 3 years ago

Hi Mr MCarlomagno, thanks for the code, it's very heplful. But, I have a problem in field faceDetected. Can you tell me, why? Here's the warning. Thank You. Have a great day.

════════ Exception caught by widgets library ═══════════════════════════════════ The following LateError was thrown building FutureBuilder(dirty, dependencies: [MediaQuery], state: _FutureBuilderState#14457): LateInitializationError: Field 'faceDetected' has not been initialized.

MCarlomagno commented 2 years ago

Hi! I'm sorry for the late answer, I will check it out and then I will give you a response as soon as I figure out the bug, thanks!

betoflakes commented 2 years ago

I faced this case, I changed from late Face faceDeteced to Face? faceDeteced;