question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Can't set options.storage

See original GitHub issue

I’m working on an integration of JSXC (v4.1.1) with Openfire (4.6.0-beta). Part of the integration allows an administrative user to make and persist changes to the JSXC configuration options. To be able to allow for such dynamics, the options to be used are exposed through a web endpoint (such as https://xmpp.igniterealtime.org:7483/jsxc/options.json ).

The web page that loads the web application itself firsts loads that endpoint, and uses its content to initialize JSXC. Look at the source of https://xmpp.igniterealtime.org:7483/jsxc/ to see that in action.

I’ve been pretty successful in applying changes to the options to be used this way. I can pretty much add all options as documented on https://jsxc.readthedocs.io/en/latest/api.html

All, but one, that is. Whenever I try to set options.storage the development console of the browser logs these errors whenever I reload the page:

jsxc.bundle.js:2 Uncaught TypeError: t.backend.setItem is not a function
    at t.testStorage (jsxc.bundle.js:2)
    at new t (jsxc.bundle.js:2)
    at Function.t.getStorage (jsxc.bundle.js:2)
    at Function.t.getOptions (jsxc.bundle.js:2)
    at Function.t.getOption (jsxc.bundle.js:2)
    at Function.e.initialize (jsxc.bundle.js:2)
    at Function.t.init (jsxc.bundle.js:2)
    at new t (jsxc.bundle.js:2)
    at Object.success ((index):70)
    at c (jquery-3.5.1.min.js:2)

and

jsxc.bundle.js:2 Uncaught TypeError: t.backend.removeItem is not a function
    at o (jsxc.bundle.js:2)
    at jsxc.bundle.js:2

My experience with front-end development is limited, so I’m uncertain if this actually is an issue within JSXC. It might be me, messing up somewhere. That said, all other options that I add in a similar fashion do seem to work…

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:5 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
sualkocommented, Aug 2, 2020

I had to use storage rather than backend though. Was that a mistake on your end, or am I doing something different to what you are suggesting?

It was a mistake on my end. Sorry, but nice to hear that you get it working. 🎉

0reactions
sualkocommented, Aug 2, 2020

That’s great. Thanks for your effort. If you like you can also put it to the community plugin on the installation page of our website. Just create a pr in https://github.com/jsxc/jsxc.org

Read more comments on GitHub >

github_iconTop Results From Across the Web

"Change" option not available to manage storage spaces
this issue, in every case there is a "change" entry on the right menu near the drive space description. Mine is missing. I...
Read more >
Working with storage for Amazon RDS DB instances
Specify how you want your data stored in Amazon RDS by choosing a storage type and providing a storage size when you create...
Read more >
Check your storage or change your plan - Google One Help
Tap Change membership plan. Choose your new storage limit. You can select a monthly or annual subscription. To add more storage, under "Upgrade...
Read more >
If you can't connect to the App Store, iTunes Store, or other ...
On your Mac: Open System Settings, click General, then click Date & Time. Or open System Preferences, then choose Date & Time. On...
Read more >
Storage updates in Android 11
If your app uses the legacy storage model and previously targeted Android 10 or lower, you might be storing data in a directory...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found