Advertisement
chodorowicz

Untitled

Jul 29th, 2011
206
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Rails 0.26 KB | None | 0 0
  1.     def artist_name
  2.         if @artist_name
  3.             @artist_name
  4.         elsif composition
  5.             composition.artist.name
  6.         else
  7.             ""
  8.         end
  9.     end
  10.  
  11.     def composition_name
  12.         if @composition_name
  13.             @composition_name
  14.         elsif composition
  15.             composition.name
  16.         else
  17.             ""
  18.         end
  19.     end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement