🐛 Fix APNs notification does not contains subtitle
This commit is contained in:
parent
fed972fc16
commit
17db3c4998
@ -95,6 +95,9 @@ func PushAppleNotify(token string, in *proto.NotifyRequest) error {
|
|||||||
Custom("metadata", metadata).
|
Custom("metadata", metadata).
|
||||||
Sound("default").
|
Sound("default").
|
||||||
MutableContent()
|
MutableContent()
|
||||||
|
if in.Subtitle != nil {
|
||||||
|
data = data.AlertSubtitle(*in.Subtitle)
|
||||||
|
}
|
||||||
if in.Avatar != nil {
|
if in.Avatar != nil {
|
||||||
data = data.Custom("avatar", *in.Avatar)
|
data = data.Custom("avatar", *in.Avatar)
|
||||||
}
|
}
|
||||||
@ -118,7 +121,7 @@ func PushAppleNotify(token string, in *proto.NotifyRequest) error {
|
|||||||
Dur("elapsed", time.Since(start)).
|
Dur("elapsed", time.Since(start)).
|
||||||
Str("reason", resp.Reason).
|
Str("reason", resp.Reason).
|
||||||
Int("status", resp.StatusCode).
|
Int("status", resp.StatusCode).
|
||||||
Msg("Push a notify via firebase")
|
Msg("Push a notify via apple")
|
||||||
}
|
}
|
||||||
|
|
||||||
return nil
|
return nil
|
||||||
|
Loading…
Reference in New Issue
Block a user