From: Jean-Philippe Lang Date: Sat, 5 Jul 2014 10:43:45 +0000 (+0000) Subject: Fixed relative "source" links in email notifications (#3483). X-Git-Tag: 2.6.0~106 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=5f4ba3d6d5a714510eb8f8b14c0b498d0cb0d3e0;p=redmine.git Fixed relative "source" links in email notifications (#3483). Patch by William Baum. git-svn-id: http://svn.redmine.org/redmine/trunk@13219 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb index 9cb5b9687..f728010c2 100644 --- a/app/helpers/application_helper.rb +++ b/app/helpers/application_helper.rb @@ -863,7 +863,7 @@ module ApplicationHelper if repository && User.current.allowed_to?(:browse_repository, project) name =~ %r{^[/\\]*(.*?)(@([^/\\@]+?))?(#(L\d+))?$} path, rev, anchor = $1, $3, $5 - link = link_to h("#{project_prefix}#{prefix}:#{repo_prefix}#{name}"), {:controller => 'repositories', :action => (prefix == 'export' ? 'raw' : 'entry'), :id => project, :repository_id => repository.identifier_param, + link = link_to h("#{project_prefix}#{prefix}:#{repo_prefix}#{name}"), {:only_path => only_path, :controller => 'repositories', :action => (prefix == 'export' ? 'raw' : 'entry'), :id => project, :repository_id => repository.identifier_param, :path => to_path_param(path), :rev => rev, :anchor => anchor},