post replacements: add /post_replacements view.

This commit is contained in:
evazion
2017-06-22 16:42:56 -05:00
parent 13d49467a2
commit 8b4e598a12
4 changed files with 64 additions and 0 deletions

View File

@@ -101,6 +101,14 @@ module ApplicationHelper
time_tag(time.strftime("%Y-%m-%d %H:%M"), time)
end
def external_link_to(url)
if url =~ %r!\Ahttps?://!i
link_to url, {}, {rel: :nofollow}
else
url
end
end
def link_to_ip(ip)
link_to ip, moderator_ip_addrs_path(:search => {:ip_addr => ip})
end