single-file-core 1.0.27 → 1.0.29

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -148,7 +148,11 @@
148
148
  if (url && saveDate) {
149
149
  let options;
150
150
  if (browser && browser.runtime && browser.runtime.sendMessage) {
151
- options = await browser.runtime.sendMessage({ method: "tabs.getOptions", url });
151
+ try {
152
+ options = await browser.runtime.sendMessage({ method: "tabs.getOptions", url });
153
+ } catch (error) {
154
+ options = { displayInfobar: true };
155
+ }
152
156
  } else {
153
157
  options = { displayInfobar: true };
154
158
  }
@@ -166,7 +170,6 @@
166
170
  async function initInfobar(url, saveDate, infoData) {
167
171
  let infobarElement = document.querySelector(INFOBAR_TAGNAME);
168
172
  if (!infobarElement) {
169
- url = url.split("url: ")[1];
170
173
  saveDate = saveDate.split("saved date: ")[1];
171
174
  if (infoData && infoData.length > 1) {
172
175
  let content = infoData[0].split("info: ")[1].trim();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "single-file-core",
3
- "version": "1.0.27",
3
+ "version": "1.0.29",
4
4
  "description": "SingleFile Core",
5
5
  "author": "Gildas Lormeau",
6
6
  "license": "AGPL-3.0-or-later",