This is one of those things, that maybe so simple I\'ll never find it because everyone else already knows it.
I\'ve got objects I have to check for nil in my views s
The Ruby community has put an incredible amount of attention to automating this idiom. These are the solutions I know of:
The most well-known is probably the try method in Rails. However, it has received some criticism.
In any case, I think Ben's solution is perfectly sufficient.