diff --git a/app/helpers/albums_helper.rb b/app/helpers/albums_helper.rb index 338f26ec918203be9c501f6eba5f91bdf8e3464e..337ce608f0109ffdadd6e31c4f8188bc100617f3 100644 --- a/app/helpers/albums_helper.rb +++ b/app/helpers/albums_helper.rb @@ -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 diff --git a/app/views/albums/_album.html.haml b/app/views/albums/_album.html.haml index 3e4bf3483c97d11ad75ef830c321e0b6a11e976f..bf28846b5ed7d4bb6bb2a812c3deb5db38e19f1f 100644 --- a/app/views/albums/_album.html.haml +++ b/app/views/albums/_album.html.haml @@ -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))