diff options
| author | 2020-02-25 16:50:17 +0000 | |
|---|---|---|
| committer | 2020-02-25 16:50:17 +0000 | |
| commit | 5608c1cdc7daecc082baf72844d5fe276e56885b (patch) | |
| tree | 9864ee7892ac83f8ed12196937c39c6a78c70e7c /modules/google.py | |
| parent | send_modes takes list[tuple[s,s]], add !down, !deop yourself last (diff) | |
| signature | ||
show !g snippet when available, title when not
Diffstat (limited to 'modules/google.py')
| -rw-r--r-- | modules/google.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/modules/google.py b/modules/google.py index 6cddb8a3..0af8da66 100644 --- a/modules/google.py +++ b/modules/google.py @@ -35,9 +35,10 @@ class Module(ModuleManager.BaseModule): if "items" in page and len(page["items"]): item = page["items"][0] link = item["link"] - title = utils.parse.line_normalise(item["title"]) + text = utils.parse.line_normalise( + item["snippet"] or item["title"]) event["stdout"].write( - "(%s) %s - %s" % (phrase, title, link)) + "%s: %s - %s" % (event["user"].nickname, text, link)) else: event["stderr"].write("No results found") else: |
