#NEWLINE# def get( self , * args , **kwargs ) : #NEWLINE# #INDENT# '\n        Performs the query and returns a single object matching the given\n        keyword arguments.\n        ' #NEWLINE# custom_pk = self . model . _meta . pk . attname #NEWLINE# attributes_set = set ( ( attr for attr in [ 'id__exact' , 'pk__exact' , ( '%s__exact' % custom_pk ) ] if ( attr in kwargs . keys ( ) ) ) ) #NEWLINE# exact_match = list ( attributes_set ) #NEWLINE# if ( kwargs . keys ( ) == [ 'id' ] ) : #NEWLINE# #INDENT# return self . _get_from_id_or_pk ( id = kwargs [ 'id' ] ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# if ( kwargs . keys ( ) == [ 'pk' ] ) : #NEWLINE# #INDENT# return self . _get_from_id_or_pk ( pk = kwargs [ 'pk' ] ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# if ( kwargs . keys ( ) == [ custom_pk ] ) : #NEWLINE# #INDENT# return self . _get_from_id_or_pk ( pk = kwargs [ custom_pk ] ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# if ( len ( exact_match ) == 1 ) : #NEWLINE# #INDENT# return self . _get_from_id_or_pk ( pk = kwargs [ exact_match [ 0 ] ] ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# return super ( RemoteQuerySet , self ) . get ( * args , ** kwargs )