@wrap_exceptions<EOL><INDENT>def get_last_doc(self):<DEDENT>
<EOL>try:<EOL><INDENT>result = self.solr.search('<STR_LIT>', sort='<STR_LIT>', rows=<NUM_LIT:1>)<EOL><DEDENT>except ValueError:<EOL><INDENT>return None<EOL><DEDENT>for r in result:<EOL><INDENT>r['<STR_LIT>'] = r.pop(self.unique_key)<EOL>return r<EOL><DEDENT>
Returns the last document stored in the Solr engine.