Commit 397c3da9758c03a215a308c011f94261d9c61cfa

Authored by Martin Bastien
1 parent 6880ace1

Fix user path in markdown

Showing 1 changed file with 2 additions and 2 deletions   Show diff stats
lib/gitlab/markdown.rb
@@ -17,7 +17,7 @@ module Gitlab @@ -17,7 +17,7 @@ module Gitlab
17 # Examples 17 # Examples
18 # 18 #
19 # >> gfm("Hey @david, can you fix this?") 19 # >> gfm("Hey @david, can you fix this?")
20 - # => "Hey <a href="/gitlab/team_members/1">@david</a>, can you fix this?" 20 + # => "Hey <a href="/u/david">@david</a>, can you fix this?"
21 # 21 #
22 # >> gfm("Commit 35d5f7c closes #1234") 22 # >> gfm("Commit 35d5f7c closes #1234")
23 # => "Commit <a href="/gitlab/commits/35d5f7c">35d5f7c</a> closes <a href="/gitlab/issues/1234">#1234</a>" 23 # => "Commit <a href="/gitlab/commits/35d5f7c">35d5f7c</a> closes <a href="/gitlab/issues/1234">#1234</a>"
@@ -160,7 +160,7 @@ module Gitlab @@ -160,7 +160,7 @@ module Gitlab
160 160
161 def reference_user(identifier) 161 def reference_user(identifier)
162 if member = @project.users_projects.joins(:user).where(users: { username: identifier }).first 162 if member = @project.users_projects.joins(:user).where(users: { username: identifier }).first
163 - link_to("@#{identifier}", project_team_member_url(@project, member), html_options.merge(class: "gfm gfm-team_member #{html_options[:class]}")) if member 163 + link_to("@#{identifier}", user_path(identifier), html_options.merge(class: "gfm gfm-team_member #{html_options[:class]}")) if member
164 end 164 end
165 end 165 end
166 166