diff options
author | Giuseppe Bilotta <giuseppe.bilotta@gmail.com> | 2007-04-08 15:28:46 +0000 |
---|---|---|
committer | Giuseppe Bilotta <giuseppe.bilotta@gmail.com> | 2007-04-08 15:28:46 +0000 |
commit | 15c0b674d60d719c19f4ebeefca33664d03d16ad (patch) | |
tree | cd57a2e6d858f8fad69260c1dd3512d9cab607e5 /data/rbot | |
parent | 42045b5df29519cb4307ac433c6fd0d4ba5f157b (diff) |
url plugin: show value of content-encoding if present
Diffstat (limited to 'data/rbot')
-rw-r--r-- | data/rbot/plugins/url.rb | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/data/rbot/plugins/url.rb b/data/rbot/plugins/url.rb index d1c9b6bb..a1a325eb 100644 --- a/data/rbot/plugins/url.rb +++ b/data/rbot/plugins/url.rb @@ -67,6 +67,11 @@ class UrlPlugin < Plugin end debug response.to_hash.inspect + + enc = response['content-encoding'] + + extra << ", #{Bold}encoding#{Bold}: #{enc}" if enc + unless @bot.config['url.titles_only'] # content doesn't have title, just display info. size = response['content-length'].gsub(/(\d)(?=\d{3}+(?:\.|$))(\d{3}\..*)?/,'\1,\2') rescue nil |