title: Ruby on Rails: conditionally display a partial
body: <p>I'm not sure if I'm doing the best approach here, but I have a block of data that I want to show after a search is done and to not be there at all before.  First of all, there is nothing to show, and second the model it references is nil so it throws an exception.</p>
  
  <p>I placed this block in a partial template and added it the appropriate spot in my layout.  Is there a way to cleanly render the partial conditionally?  Is there a better way to approach this problem?</p>