googlearchive / web-push-encryption

[Deprecated] Encryption Utilities for Web Push protocol
Apache License 2.0
84 stars 23 forks source link

Status #52

Closed bradennapier closed 8 years ago

bradennapier commented 8 years ago

Is it not possible to get the actual status of the push ? It says Status: 201 - Created... How would I verify the push was sent? Every other document clearly indicates you should be lookign at the status to determine if the push was successfully sent

samthor commented 8 years ago

You should check the returned Promise.

const out = webpush.sendWebPush('hello', subscription);
out.catch(err => {
  console.warn('Failure!', err);
});