@check_source<EOL><INDENT>def reconnect(self, old_node, new_node):<DEDENT>
self._check_node(old_node)<EOL>self._check_node(new_node)<EOL>if old_node.id == new_node.id:<EOL><INDENT>return<EOL><DEDENT>old_rel = _rel_helper(lhs='<STR_LIT>', rhs='<STR_LIT>', ident='<STR_LIT:r>', **self.definition)<EOL>result, meta = self.source.cypher(<EOL>"<STR_LIT>"<EOL>"<STR_LIT>" + old_rel + "<STR_LIT>", {'<STR_LIT>': old_node.id})<EOL>if result:<EOL><INDENT>node_properties = _get_node_properties(result[<NUM_LIT:0>][<NUM_LIT:0>])<EOL>existing_properties = node_properties.keys()<EOL><DEDENT>else:<EOL><INDENT>raise NotConnected('<STR_LIT>', self.source, old_node)<EOL><DEDENT>new_rel = _rel_helper(lhs='<STR_LIT>', rhs='<STR_LIT>', ident='<STR_LIT>', **self.definition)<EOL>q = "<STR_LIT>""<STR_LIT>""<STR_LIT>" + old_rel<EOL>q += "<STR_LIT>" + new_rel<EOL>for p in existing_properties:<EOL><INDENT>q += "<STR_LIT>".format(p, p)<EOL><DEDENT>q += "<STR_LIT>"<EOL>self.source.cypher(q, {'<STR_LIT>': old_node.id, '<STR_LIT>': new_node.id})<EOL>
Disconnect old_node and connect new_node copying over any properties on the original relationship.

Useful for preventing cardinality violations

:param old_node:
:param new_node:
:return: None