jpush.getRegistrationID change await to then

hmxc
张萌 3 years ago
parent 28e6d1de37
commit a9ca0ee61e

@ -60,7 +60,8 @@ void main() async {
production: false,
debug: true, // debug
);
String? id = await JPush().getRegistrationID();
String? id;
JPush().getRegistrationID().then((value) => id = value);
print('jpush RegistrationID is $id');
LoggerData.addData(id);
runApp(MyApp());

Loading…
Cancel
Save