Skip to content

Commit abcd94b

Browse files
jeacott1flovilmart
jeacott1
authored andcommitted
fixes 64k limit on GCM push. (#49)
devices = new Array(...devices); expands to include apply(,args) which is limited.
1 parent 8e087cf commit abcd94b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/GCM.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ function GCM(args) {
2626
GCM.prototype.send = function(data, devices) {
2727
let pushId = randomString(10);
2828
// Make a new array
29-
devices = new Array(...devices);
29+
devices=devices.slice(0);
3030
let timestamp = Date.now();
3131
// For android, we can only have 1000 recepients per send, so we need to slice devices to
3232
// chunk if necessary

0 commit comments

Comments
 (0)