refactor: Remove Protolude.Conv from Proxy

This commit is contained in:
monacoremo
2021-11-12 20:25:22 +01:00
committed by Remo
parent 3820590649
commit f228cccbae
+5 -6
View File
@@ -8,13 +8,12 @@ module PostgREST.Config.Proxy
, toURI
) where
import qualified Data.Text as T
import Data.Maybe (fromJust)
import Data.Text (pack, toLower)
import Network.URI (URI (..), URIAuth (..), isAbsoluteURI, parseURI)
import Protolude hiding (Proxy, dropWhile, get, intercalate,
toLower, toS, (&))
import Protolude.Conv (toS)
import Protolude hiding (Proxy)
data Proxy = Proxy
{ proxyScheme :: Text
@@ -48,8 +47,8 @@ fAnd fs x = all ($ x) fs
isSchemeValid :: URI -> Bool
isSchemeValid URI {uriScheme = s}
| toLower (pack s) == "https:" = True
| toLower (pack s) == "http:" = True
| T.toLower (T.pack s) == "https:" = True
| T.toLower (T.pack s) == "http:" = True
| otherwise = False
isQueryValid :: URI -> Bool