From 79080e97c0ef1863c1e80a9ddf30c69323af1ca7 Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Tue, 21 Apr 2009 11:14:53 -0700 Subject: Stop extending core classes This removes the #unicorn_peeraddr methods from TCPSocket and UNIXSocket core classes. Instead, just move that logic into the only place it needs to be used in HttpRequest. --- lib/unicorn/socket.rb | 13 ------------- 1 file changed, 13 deletions(-) (limited to 'lib/unicorn/socket.rb') diff --git a/lib/unicorn/socket.rb b/lib/unicorn/socket.rb index 5a3bfd7..850ad85 100644 --- a/lib/unicorn/socket.rb +++ b/lib/unicorn/socket.rb @@ -1,18 +1,5 @@ require 'socket' -class UNIXSocket - UNICORN_PEERADDR = '127.0.0.1'.freeze - def unicorn_peeraddr - UNICORN_PEERADDR - end -end - -class TCPSocket - def unicorn_peeraddr - peeraddr.last - end -end - module Unicorn module SocketHelper include Socket::Constants -- cgit v1.2.3-24-ge0c7