Sha256: 0012d86a47a82d507473e9b14b05f6822872c6347e086348c1c3a1ea9ac82ccd
Contents?: true
Size: 550 Bytes
Versions: 2
Compression:
Stored size: 550 Bytes
Contents
module PushToSNS class AndroidPushNotification < BasicPushNotification def message { GCM: { data: default_payload.deeper_merge(payload) }.to_json } end private def default_payload basic_payload = {} basic_payload[:title] = payload[:title] if payload[:title] basic_payload[:message] = payload[:message] if payload[:message] basic_payload[:smallIcon] = payload[:small_icon] if payload[:small_icon] basic_payload[:sound] = payload[:sound] if payload[:sound] basic_payload end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
push_to_sns-0.4.1 | lib/push_to_sns/android_push_notification.rb |
push_to_sns-0.4.0 | lib/push_to_sns/android_push_notification.rb |