Added better handling of wireProtocol for cursors