diff options
| author | Joey Hess <joey@kitenet.net> | 2014-04-18 14:44:46 -0400 |
|---|---|---|
| committer | Joey Hess <joey@kitenet.net> | 2014-04-18 14:44:46 -0400 |
| commit | 498fe2cd2551f3a4fdbcbd2b99fdfdbefa0879d0 (patch) | |
| tree | 7635f7a2b9f6be2763d90a3cb3029085522352be /Propellor | |
| parent | b2d6393bf40f73d25871c678309649e75c159f24 (diff) | |
propellor spin
Diffstat (limited to 'Propellor')
| -rw-r--r-- | Propellor/Property/Dns.hs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/Propellor/Property/Dns.hs b/Propellor/Property/Dns.hs index 5b4b2622..260f3aa6 100644 --- a/Propellor/Property/Dns.hs +++ b/Propellor/Property/Dns.hs @@ -133,8 +133,8 @@ rValue (TXT s) = [q] ++ filter (/= q) s ++ [q] -- -- * Always be larger than the passed SerialNumber -- * Always be larger than the serial number in the Zone record. -nextSerial :: Zone -> SerialNumber -> Zone -nextSerial (Zone soa l) oldserial = Zone soa' l +nextSerialNumber :: Zone -> SerialNumber -> Zone +nextSerialNumber (Zone soa l) oldserial = Zone soa' l where soa' = soa { sSerial = succ $ max (sSerial soa) oldserial } @@ -152,7 +152,7 @@ nextSerial (Zone soa l) oldserial = Zone soa' l writeZoneFile :: Zone -> FilePath -> IO () writeZoneFile z f = do oldserial <- nextZoneFileSerialNumber f - let z'@(Zone soa' _) = nextSerial z oldserial + let z'@(Zone soa' _) = nextSerialNumber z oldserial writeFile f (genZoneFile z') writeFile (zoneSerialFile f) (show $ sSerial soa') |
