Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

发送自定义消息的时候,extar 类型是空,会有异常 #6

Open
coder-wusichao opened this issue Sep 18, 2018 · 0 comments

Comments

@coder-wusichao
Copy link

实例化 JPushMessage 的时候,extar 类型是空,会有异常

case 'receivePushMsg':
{
var map = call.arguments;
var extras = map['extras'];
if (extras != null) {
try {
if (extras is String) {
extras = json.decode(extras);
}
} catch (e) {}
}
_recvCustomMsgController.add(new JPushMessage(
title: map['title'],
message: map['message'] ?? map['content'],
contentType: map['contentType'] ?? map['content_type'],
extras: extras));
}
break;

JPushMessage({this.message, this.contentType, this.title, this.extras});

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant