the album create doesn't crash the app

This commit is contained in:
ilya 2010-08-18 20:14:31 -07:00
parent 00c80ed662
commit 3243435015
2 changed files with 1 additions and 10 deletions

View file

@ -14,13 +14,4 @@ module AlbumsHelper
'Your Albums'
end
end
def album_person(album)
person = album.person
if album.person_id == current_user.person.id
link_to "you", user_path(current_user)
else
link_to person.real_name, person_path(person)
end
end
end

View file

@ -5,7 +5,7 @@
%div.time
by
= album_person(post)
= link_to ((current_user.person == post.person)? 'you' : post.person.real_name), person_path(post.person)
%br
= link_to(how_long_ago(post), object_path(post))