small fix

This commit is contained in:
Harry Bomrah 2014-11-27 18:28:37 +08:00
parent 179a14d717
commit eeebed8d7b
1 changed files with 1 additions and 1 deletions

View File

@ -478,10 +478,10 @@ module ApplicationHelper
end
def get_target(link)
target = "_blank"
if link.nil?
link = link.split("?").first
temp_url = URI.parse(link)
target = "_blank"
if temp_url.host.nil?
target = "_self"
end