Fix bug with querying.

Correct potential missuse of body object.

Change-Id: I048d0c9a4e7227b6b1c8adc8db40f5f9f146209d