aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStephen Blott2015-05-15 11:02:49 +0100
committerStephen Blott2015-05-15 11:02:49 +0100
commit93000bc401417954c8d9c1f52ef449292c2cd6fa (patch)
tree76785ef9bbdfda1459f596548dddebe454d608fc
parentae44f35a653e76a2efbcb29f83c3fefa0ee0ab78 (diff)
downloadvimium-93000bc401417954c8d9c1f52ef449292c2cd6fa.tar.bz2
Use query text as title, if necessary and possible.
-rw-r--r--background_scripts/completion.coffee4
1 files changed, 4 insertions, 0 deletions
diff --git a/background_scripts/completion.coffee b/background_scripts/completion.coffee
index 82a8f310..c9a03629 100644
--- a/background_scripts/completion.coffee
+++ b/background_scripts/completion.coffee
@@ -245,6 +245,10 @@ class HistoryCompleter
catch
null
+ # If this history item does not have a title and we found its query text above, then use its query
+ # text as its title.
+ entry.title ||= insertText if insertText?
+
new Suggestion
queryTerms: queryTerms
type: "history"