Skip to content

Commit 649d7e1

Browse files
p-mongop
andauthored
RUBY-2132 simplify connection connectedness check (#1945)
Co-authored-by: Oleg Pudeyev <oleg@bsdpower.com>
1 parent 060fff6 commit 649d7e1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/mongo/server/connection_common.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ class ConnectionCommon
4242
#
4343
# @deprecated
4444
def connected?
45-
!!@socket && @socket.alive?
45+
!!socket
4646
end
4747

4848
# @return [ Integer ] pid The process id when the connection was created.

0 commit comments

Comments
 (0)