Commit 5658029f authored by Libin Lu's avatar Libin Lu Committed by GitHub

Merge pull request #1042 from 0is1/master

Fix Android rescheduled notifications firing immediately
parents 9f9e6678 83846143
...@@ -58,11 +58,11 @@ public class FIRLocalMessagingHelper { ...@@ -58,11 +58,11 @@ public class FIRLocalMessagingHelper {
return; return;
} }
long fireDate = Math.round(bundle.getDouble("fire_date")); Long fireDate = bundle.getLong("fire_date", -1);
if(fireDate == 0){ if (fireDate == -1) {
fireDate = Math.round(bundle.getLong("fire_date")); fireDate = (long) bundle.getDouble("fire_date", -1);
} }
if (fireDate == 0) { if (fireDate == -1) {
Log.e(TAG, "failed to schedule notification because fire date is missing"); Log.e(TAG, "failed to schedule notification because fire date is missing");
return; return;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment