From 68ffe9583c8d268b6292da3c9854965dcd6ce4a7 Mon Sep 17 00:00:00 2001 From: Abe Jellinek Date: Thu, 31 Jul 2025 15:47:42 -0400 Subject: [PATCH] Clean up JSDoc comments and unused field (#5443) --- chrome/content/zotero/xpcom/cookieSandbox.js | 9 +++------ chrome/content/zotero/xpcom/utilities_internal.js | 2 +- 2 files changed, 4 insertions(+), 7 deletions(-) diff --git a/chrome/content/zotero/xpcom/cookieSandbox.js b/chrome/content/zotero/xpcom/cookieSandbox.js index c735c451bf..f16113f019 100755 --- a/chrome/content/zotero/xpcom/cookieSandbox.js +++ b/chrome/content/zotero/xpcom/cookieSandbox.js @@ -28,10 +28,10 @@ * * @constructor * @param {browser} [browser] Hidden browser object - * @param {String|nsIURI} uri URI of page to manage cookies for (cookies for domains that are not + * @param {String|nsIURI} [uri] URI of page to manage cookies for (cookies for domains that are not * subdomains of this URI are ignored) - * @param {String} cookieData Cookies with which to initiate the sandbox - * @param {String} userAgent User agent to use for sandboxed requests + * @param {String} [cookieData] Cookies with which to initiate the sandbox + * @param {String} [userAgent] User agent to use for sandboxed requests */ Zotero.CookieSandbox = function (browser, uri, cookieData, userAgent) { this._cookies = {}; @@ -52,9 +52,6 @@ Zotero.CookieSandbox = function (browser, uri, cookieData, userAgent) { if (userAgent) this.userAgent = userAgent; - this._observerService = Components.classes["@mozilla.org/observer-service;1"]. - getService(Components.interfaces.nsIObserverService); - if (browser) { this.attachToBrowser(browser); } diff --git a/chrome/content/zotero/xpcom/utilities_internal.js b/chrome/content/zotero/xpcom/utilities_internal.js index d53b41832b..abc44033e6 100644 --- a/chrome/content/zotero/xpcom/utilities_internal.js +++ b/chrome/content/zotero/xpcom/utilities_internal.js @@ -1342,7 +1342,7 @@ Zotero.Utilities.Internal = { /** * Run translation on a Document to try to find a PDF URL * - * @param {doc} Document + * @param {Document} doc * @param {Zotero.CookieSandbox} cookieSandbox * @return {{ title: string, url: string } | false} - PDF attachment title and URL, or false if none found */