Use the newest requirements in lib to define an ID prefix for the Session type
This commit is contained in:
parent
7a937355d2
commit
0d19c4f8dc
1 changed files with 3 additions and 1 deletions
|
@ -9,12 +9,14 @@ module Session (
|
||||||
) where
|
) where
|
||||||
|
|
||||||
import Data.Text (Text)
|
import Data.Text (Text)
|
||||||
import qualified Hanafuda.ID as Hanafuda (ID)
|
import qualified Hanafuda.ID as Hanafuda (ID, IDType(..), Prefix(..))
|
||||||
import Hanafuda.KoiKoi (PlayerID)
|
import Hanafuda.KoiKoi (PlayerID)
|
||||||
import Network.WebSockets (Connection)
|
import Network.WebSockets (Connection)
|
||||||
import qualified Player (T(..))
|
import qualified Player (T(..))
|
||||||
|
|
||||||
type ID = Hanafuda.ID T
|
type ID = Hanafuda.ID T
|
||||||
|
instance Hanafuda.IDType T where
|
||||||
|
prefix = Hanafuda.Prefix "Session"
|
||||||
type Status = Maybe Player.T
|
type Status = Maybe Player.T
|
||||||
data T = T {
|
data T = T {
|
||||||
connection :: Connection
|
connection :: Connection
|
||||||
|
|
Loading…
Add table
Reference in a new issue