salemove/freddy-hs

View on GitHub

Showing 3 of 3 total issues

Use <$>
Open

generateCorrelationId = do
  uuid <- newUUID
  return $ UUID.toText uuid

Found

do uuid <- newUUID
   return $ UUID.toText uuid

Perhaps

do UUID.toText <$> newUUID

Redundant bracket
Open

      if (ResultType.fromText msgType) == ResultType.Success then
Severity: Minor
Found in src/Network/Freddy.hs by hlint

Found

(ResultType.fromText msgType) == ResultType.Success

Perhaps

ResultType.fromText msgType == ResultType.Success

Use newtype instead of data
Open

data EchoRequest = EchoRequest {
  message :: String
} deriving (Generic, Show)
Severity: Minor
Found in examples/echo_client.hs by hlint

Found

data EchoRequest
  = EchoRequest {message :: String}
  deriving (Generic, Show)

Perhaps

newtype EchoRequest
  = EchoRequest {message :: String}
  deriving (Generic, Show)

Applying this change:

  • decreases laziness
Severity
Category
Status
Source
Language