minor refactor
minor changes to SocketManager