From 06f7f711dd13f7926c129fe07114a29eb9cd7103 Mon Sep 17 00:00:00 2001 From: Toks Date: Thu, 11 Apr 2013 15:00:20 -0400 Subject: [PATCH] fixes #1280 --- app/helpers/posts_helper.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/helpers/posts_helper.rb b/app/helpers/posts_helper.rb index 0ee595eb4..763b62860 100644 --- a/app/helpers/posts_helper.rb +++ b/app/helpers/posts_helper.rb @@ -27,7 +27,7 @@ module PostsHelper source_link = link_to(text, post.normalized_source) source_search = "source:#{text}" elsif post.source =~ /^http/ - text = truncate(post.normalized_source.sub(/^https?:\/\/(?:www)?/, "")) + text = truncate(post.normalized_source.sub(/^https?:\/\/(?:www\.)?/, "")) source_link = link_to(truncate(text, :length => 20), post.normalized_source) source_search = "source:#{post.source.sub(/[^\/]*$/, "")}" else