# Strange partial error

**URL:** <https://www.ruby-forum.com/t/strange-partial-error/60638>\
**Category:** Rails\
**Created:** [May 16, 2006, 1:37pm UTC](https://www.ruby-forum.com/t/strange-partial-error/60638 "2006-05-16T13:37:45Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![samj](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/77aa72/32.png) [@samj](https://www.ruby-forum.com/u/samj)\
**Post date:** [May 16, 2006, 1:37pm UTC](https://www.ruby-forum.com/t/strange-partial-error/60638/1 "2006-05-16T13:37:45Z")

</div>

I’m getting this weird partial problem.

I’m calling the partial like so:

\<%= render :partial =\> partial,  
:locals =\> {:message =\> message,  
:display =\> display,  
:indent =\> indent,  
:button\_type =\> button,  
:terms =\> params[:search\_terms]} %\>

The object in message can be printed out first, and then within the  
partial I can access it, and it returns false to message.nil? but when I  
try to access elements like message.title from within the partial  
template itself I get errors like this:

You have a nil object when you didn’t expect it!  
The error occured while evaluating nil.title

Any ideas?

Many thanks in advance.

CHEERS\> SAM
