Use Text instead of String

This commit is contained in:
Joscha 2018-01-28 14:36:45 +00:00
parent 5ecf9864d3
commit 8428d3bbbf

View file

@ -7,6 +7,7 @@
module EuphApi.Types
( Snowflake
, SessionID
, Nick
, UserID(..)
, UserType(..)
, Message(..)
@ -29,6 +30,9 @@ type Snowflake = T.Text
-- | ID of a session, unique across all sessions globally.
type SessionID = T.Text
-- | Nick of a user.
type Nick = T.Text
-- | Represents <http://api.euphoria.io/#userid>.
--
-- A 'UserID' identifies a user.
@ -120,9 +124,9 @@ instance FromJSON Message where
-- The fields @client_address@ and @real_client_address@ are not implemented.
data SessionView = SessionView
{ sessID :: UserID
, sessName :: String
, sessServerID :: String
, sessServerEra :: String
, sessName :: Nick
, sessServerID :: T.Text
, sessServerEra :: T.Text
, sessSessionID :: SessionID
, isStaff :: Bool
, isManager :: Bool