Simplify author_profile_link

openid
Marcin Kulik 12 years ago
parent 780dff5db1
commit 3b2dc7f998

@ -120,16 +120,12 @@ class AsciicastDecorator < ApplicationDecorator
img = "" img = ""
end end
text = img + "~#{asciicast.user.nickname}" text = img + author
path = h.profile_path(asciicast.user) path = h.profile_path(asciicast.user)
h.link_to text, path h.link_to text, path
else else
if asciicast.username.present? author
"~#{asciicast.username}"
else
"anonymous"
end
end end
end end

Loading…
Cancel
Save