Skip to content

Commit

Permalink
Generalize the type of time in determinePoolRegistrationStatus.
Browse files Browse the repository at this point in the history
This makes it easier to write property tests, as we are free to use the
type of our choice to represent time.
  • Loading branch information
jonathanknowles committed Jul 10, 2020
1 parent baeb875 commit 2865b44
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions lib/core/src/Cardano/Pool/DB.hs
Expand Up @@ -220,8 +220,9 @@ data PoolRegistrationStatus
-- determine the pool's current registration status based on the relative
-- order in which the certificates were published.
determinePoolRegistrationStatus
:: Maybe (CertificatePublicationTime, PoolRegistrationCertificate)
-> Maybe (CertificatePublicationTime, PoolRetirementCertificate)
:: Ord certificatePublicationTime
=> Maybe (certificatePublicationTime, PoolRegistrationCertificate)
-> Maybe (certificatePublicationTime, PoolRetirementCertificate)
-> PoolRegistrationStatus
determinePoolRegistrationStatus = f
where
Expand Down

0 comments on commit 2865b44

Please sign in to comment.