File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -776,7 +776,7 @@ async def reset(self):
776
776
async with self ._lock :
777
777
if self .connection :
778
778
await self .connection .disconnect ()
779
- self .connection .deregister_connect_callback (self .on_connect )
779
+ self .connection ._deregister_connect_callback (self .on_connect )
780
780
await self .connection_pool .release (self .connection )
781
781
self .connection = None
782
782
self .channels = {}
@@ -837,7 +837,7 @@ async def connect(self):
837
837
)
838
838
# register a callback that re-subscribes to any channels we
839
839
# were listening to when we were disconnected
840
- self .connection .register_connect_callback (self .on_connect )
840
+ self .connection ._register_connect_callback (self .on_connect )
841
841
else :
842
842
await self .connection .connect ()
843
843
if self .push_handler_func is not None and not HIREDIS_AVAILABLE :
Original file line number Diff line number Diff line change @@ -216,12 +216,12 @@ def repr_pieces(self):
216
216
def is_connected (self ):
217
217
return self ._reader is not None and self ._writer is not None
218
218
219
- def register_connect_callback (self , callback ):
219
+ def _register_connect_callback (self , callback ):
220
220
wm = weakref .WeakMethod (callback )
221
221
if wm not in self ._connect_callbacks :
222
222
self ._connect_callbacks .append (wm )
223
223
224
- def deregister_connect_callback (self , callback ):
224
+ def _deregister_connect_callback (self , callback ):
225
225
try :
226
226
self ._connect_callbacks .remove (weakref .WeakMethod (callback ))
227
227
except ValueError :
You can’t perform that action at this time.
0 commit comments