Skip to content

Conversation

@kjostling
Copy link

Made a small change to enable sending push notifications without body and subject (ie silent push notifications). Also forced the content_available parameter, if data is set, but Im not sure if thats needed since I could use "setParameter" to do that.

The "real" implementation should probably be to add a "setSilent" method and adjust the payload accordingly.

Good enough?

@LKaemmerling
Copy link
Collaborator

It doesn't make sense to me, to sent a notification to a user without any content... @Lloople what do you think?

@AshPowell
Copy link
Contributor

@LKDevelopment they've already consented to receiving notifications, though this doesn't inform them of anything as its not actually a notification - its more just waking the device so the app can run background updates etc

@Lloople
Copy link
Collaborator

Lloople commented May 15, 2018

It doesn’t make sense to me either. Maybe it’s better to have a method for silent notifications instead of adding code to this one.

@LKaemmerling
Copy link
Collaborator

Yeah this would be acceptable for me @kjostling could you please do this on the refactor-to-traits branch (and add tests for this case?)

@kjostling
Copy link
Author

I can have a look at that sure.
The use case for silent push notifications is to trigger app functions in background as mentioned by @AshPowell

@kjostling
Copy link
Author

Refactored here, hope I got it right.
#67

@kjostling kjostling closed this May 22, 2018
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

Successfully merging this pull request may close these issues.

4 participants