zuphilip / zotero-open-citations

Zotero Plugin for Open Citations
GNU Affero General Public License v3.0
35 stars 2 forks source link

formatURLPref error because the link to preferences #8

Open zuphilip opened 6 years ago

zuphilip commented 6 years ago

After introducing the link to the preferences in install.rdf

<em:optionsURL>chrome://zoteroopencitations/content/preferences.xul</em:optionsURL>

I see the following error

[JavaScript Error: "formatURLPref: Couldn't get pref: extensions.getAddons.link.url" {file: "resource://gre/components/nsURLFormatter.js" line: 143}]
uf_formatURLPref@resource://gre/components/nsURLFormatter.js:143:7
gListView.initialize@chrome://mozapps/content/extensions/extensions.js:2735:9
gViewController.initialize@chrome://mozapps/content/extensions/extensions.js:709:7
initialize@chrome://mozapps/content/extensions/extensions.js:211:3

It does not seem to block anything, but still I would like to fix that. I copied the optionsURL from Zutilo and I don't see this problem there:

https://github.com/willsALMANJ/Zutilo/blob/deec2c43cac8b50fbdf69f32b08952aa3961bb1e/addon/install.rdf#L21

Ping @willsALMANJ, maybe you have any ideas how solve this

wshanks commented 6 years ago

Hmm, I see this error in the console when I open the Addons Manager even when I have all addons disabled. According to this ticket for Seamonkey the extensions.getAddons.link.url preference was added to support extension signing. Looking at the patch in the ticket linked from that ticket, it looks like it is used to suggest going to addons.mozilla.org to find alternative extensions to ones that are unsigned.

I am guessing that this is minor enough to ignore (since I think the plan is to move Zotero to Electron any way -- I haven't checked on the progress on that in a while), but I will ping @dstillman here. Zotero could add in a dummy extensions.getAddons.link.url to avoid the error in the console (though it looked like the error should be caught any way?).