Add debug output
This commit is contained in:
@@ -6,6 +6,8 @@
|
|||||||
|
|
||||||
module Main where
|
module Main where
|
||||||
|
|
||||||
|
import Debug.Trace
|
||||||
|
|
||||||
import Control.Monad.IO.Class (liftIO)
|
import Control.Monad.IO.Class (liftIO)
|
||||||
import Data.ByteString (ByteString)
|
import Data.ByteString (ByteString)
|
||||||
import Data.CharSet.ByteSet (ByteSet(..))
|
import Data.CharSet.ByteSet (ByteSet(..))
|
||||||
@@ -259,6 +261,10 @@ makeApplication ApplicationOptions{..} request respond = do
|
|||||||
|
|
||||||
let isInternalClient = hostAddr >= Socket.tupleToHostAddress (10, 0, 0, 0) && hostAddr < Socket.tupleToHostAddress (11, 0, 0, 0)
|
let isInternalClient = hostAddr >= Socket.tupleToHostAddress (10, 0, 0, 0) && hostAddr < Socket.tupleToHostAddress (11, 0, 0, 0)
|
||||||
|
|
||||||
|
traceM $ show (ByteString.Char8.unpack storePath, "private", isPrivate,
|
||||||
|
"host", hostAddr,
|
||||||
|
"isInternalClient", isInternalClient
|
||||||
|
)
|
||||||
Monad.unless (isInternalClient || not isPrivate) do
|
Monad.unless (isInternalClient || not isPrivate) do
|
||||||
let headers = [ ("Content-Type", "text/plain") ]
|
let headers = [ ("Content-Type", "text/plain") ]
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user