encodeParameters (x : [])
    | hasSpace x || T.null x || T.head x == ':' = " :" <> T.encodeUtf8 x
    | otherwise                                 = " "  <> T.encodeUtf8 x
  where
     hasSpace = isJust . T.find (== ' ')
encodeParameters (x : [])
    | hasSpace x || T.null x || T.head x == ':' = " :" <> T.encodeUtf8 x
    | otherwise                                 = " "  <> T.encodeUtf8 x
  where
     hasSpace = isJust . T.find (== ' ')
encodeParameters (x : [])
    | hasSpace x || T.null x || T.head x == ':' = " :" <> T.encodeUtf8 x
    | otherwise                                 = " "  <> T.encodeUtf8 x
  where
     hasSpace = isJust . T.find (== ' ')