mirror of
https://github.com/flutter/samples.git
synced 2025-11-08 22:09:06 +00:00
Fixes exception in platform_channels (#1480)
This commit is contained in:
@@ -20,8 +20,8 @@ class _PetListScreenState extends State<PetListScreen> {
|
|||||||
final scaffoldKey = GlobalKey<ScaffoldState>();
|
final scaffoldKey = GlobalKey<ScaffoldState>();
|
||||||
|
|
||||||
@override
|
@override
|
||||||
void initState() {
|
void didChangeDependencies() {
|
||||||
super.initState();
|
super.didChangeDependencies();
|
||||||
// Receives a string of json object from the platform and converts it
|
// Receives a string of json object from the platform and converts it
|
||||||
// to PetModel.
|
// to PetModel.
|
||||||
final scaffoldMessenger = ScaffoldMessenger.of(context);
|
final scaffoldMessenger = ScaffoldMessenger.of(context);
|
||||||
|
|||||||
Reference in New Issue
Block a user