1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2025-12-30 17:12:27 +01:00
--HG--
extra : rebase_source : 703afb13e56982584751d8ae31aa26fb5e639392
This commit is contained in:
Kris Maglione
2014-07-05 23:34:26 -07:00
parent 007449a2e1
commit 72c3a75286

View File

@@ -123,7 +123,9 @@ var Bookmarks = Module("bookmarks", {
else
var [url, postData, charset] = [elem.href || elem.src, null, elem.ownerDocument.characterSet];
let options = { "-title": "Search " + elem.ownerDocument.title };
let title = elem.title || elem instanceof Ci.nsIDOMHTMLAnchorElement && elem.textContent.trim();
let options = { "-title": title || "Search " + elem.ownerDocument.title };
if (postData != null)
options["-post"] = postData;
if (charset != null && charset !== "UTF-8")