#NEWLINE# def clean( self , value ) : #NEWLINE# #INDENT# ( content_type_pk , _ , object_pk ) = value . partition ( '-' ) #NEWLINE# if _ : #NEWLINE# #INDENT# content_type = ContentType . objects . get_for_id ( content_type_pk ) #NEWLINE# return content_type . get_object_for_this_type ( pk = object_pk ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# return None