modulofcm 1.1.0 → 1.1.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: bdc31f10864691f7e97b5edbf8967f53226e9452b641887bfd8f37e0113cd76f
4
- data.tar.gz: 6192c8281134963a1ad038fc98ee4202b8647511a885092ca96518407f9c3716
3
+ metadata.gz: 28acb9061ea348421c92f32e7317380caae03056254861a023d4b4b8fed219c3
4
+ data.tar.gz: 5fcb870b676fead22e5864b65281fdabf3032ef3121cd9d3687935707c8e70e5
5
5
  SHA512:
6
- metadata.gz: c0c19a73605c65b10a64e95306270c4f20cc3244cc644a2b54b32a95fb900e5efabbb88fd3d30afbdff547da02533f1163e4d37d8ec4c0ab12f936679e137853
7
- data.tar.gz: a8e088c71c57b27af300bd70194c9fefdb38aa237503af84374e263108c4040385a48ff57e003d54c12b63ad7336673177187aaee59e594b03ce32e60d3e14e5
6
+ metadata.gz: 0e7020576e42b9c7ffed81eca829dad928c59ba7c30c062c5d63027fbc68ea7051340b682e74465d6dd4c882e763163657a996f6239f4871a6d393864447b162
7
+ data.tar.gz: 9cb0da87b564776108c0c9bcbb181b902af8f130fd3374010ee877eb311d05290147df6c91810dc986badbb303ce7ca58b8411b1dbd1c6735a286fc8159623f3
data/CHANGELOG.md CHANGED
@@ -1,5 +1,10 @@
1
1
  ## [Unreleased]
2
2
 
3
+ ## [1.1.0.1] - 2024-05-29
4
+
5
+ - Prevent NPE on nil `data`
6
+ - Fix sound for Android
7
+
3
8
  ## [1.1.0] - 2024-05-23
4
9
 
5
10
  - Send Android notifications with priority high
@@ -117,7 +117,7 @@ module Modulofcm
117
117
 
118
118
  # According to Firebase documentation, all values must be strings. So all hashes/arrays are JSON-ified and other
119
119
  # fields (including numbers) are converted to strings.
120
- payload[:data].transform_values! do |value|
120
+ payload[:data]&.transform_values! do |value|
121
121
  if value.is_a?(Hash) || value.is_a?(Array)
122
122
  value.to_json
123
123
  else
@@ -136,8 +136,8 @@ module Modulofcm
136
136
  }
137
137
  else
138
138
  {
139
- android: {
140
- priority: "high"
139
+ android: {
140
+ priority: "high"
141
141
  },
142
142
  apns: {
143
143
  payload: {
@@ -175,7 +175,7 @@ module Modulofcm
175
175
  payload[:notification][:sound] = value
176
176
  else
177
177
  payload[:apns][:payload][:aps][:sound] = value
178
- payload[:android][:sound] = value
178
+ payload[:android][:notification] = { sound: value }
179
179
  end
180
180
  end
181
181
 
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Modulofcm
4
4
 
5
- VERSION = '1.1.0'
5
+ VERSION = '1.1.0.1'
6
6
 
7
7
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: modulofcm
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.0
4
+ version: 1.1.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Matthieu Ciappara
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-05-23 00:00:00.000000000 Z
11
+ date: 2024-05-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport