eclipse / paho.mqtt.javascript

paho.mqtt.javascript
Other
1.14k stars 468 forks source link

Handle cases where localStorage access is denied #191

Closed mpcowan closed 5 years ago

mpcowan commented 5 years ago

In browsers when localStorage access is disabled for your domain the browsers will throw an Access denied error if you try to even read the localStorage property. This commit adds try/catch logic to handle the error and use the in-memory fallback.

Signed-off-by: Matt Cowan mcowan@atlassian.com

benswinburne commented 5 years ago

Any idea when this might be merged?

icraggs commented 5 years ago

Yes, when I figure out how to fix the build! Hopefully, soon.

karldanninger commented 3 years ago

Hey @icraggs any chance you could tag/release a minor bump to include this? Would be greatly appreciated!

karldanninger commented 3 years ago

Hey @jpwsutton just a friendly poke on this. Would love to see a minor bump release.

vaskoGut commented 3 years ago

it will be nice, if u make realase with that change guys

ffxsam commented 2 years ago

For anyone who wants to patch this in their project: https://www.npmjs.com/package/patch-package

paho-mqtt is obviously no longer maintained.