Navigator.of(context).pop(); gives black screen instead of closing draer code example
Example: pop and push shows black screen which needs to be pressed back flutter
Navigator.pop(context);
Navigator.push(
context,
MaterialPageRoute(builder: (context) => SecondActivity()),
);