79759831

Date: 2025-09-09 11:34:27
Score: 2
Natty:
Report link

Bad:

if(!context.mounted) return;

Good:

if(!mounted) return;

if you check context.mounted and your context is already popped(if i press the back button) then you will get an exception and your app will be crashed.

always use mounted if you want to check your current context is not popped.

safe and secure.

Reasons:
  • Low length (0.5):
  • No code block (0.5):
  • Low reputation (1):
Posted by: Arunpandian