refactor: hlint
This commit is contained in:
parent
cadb18df7b
commit
fc49f46f50
@ -11,6 +11,7 @@
|
||||
- ignore: { name: "Use ++" }
|
||||
- ignore: { name: "Use ***" }
|
||||
- ignore: { name: "Redundant void" }
|
||||
- ignore: { name: "Too strict maybe" }
|
||||
|
||||
- arguments:
|
||||
- -XQuasiQuotes
|
||||
|
||||
@ -150,9 +150,7 @@ withFailover' testTarget' f@Failover{..} mode detAcceptable act = withFailoverRe
|
||||
$logErrorS "withFailover'" $ tshow (hashUnique alreadyTested) <> " recording failure for item " <> failoverLabel
|
||||
atomically . modifyTVar failover $ \failover' -> if
|
||||
| views (P.focus . _failoverReferences) (Set.member currentlyTesting) failover'
|
||||
-> case P.next failover' of
|
||||
Just failover'' -> failover''
|
||||
Nothing -> failover'
|
||||
-> fromMaybe failover' $ P.next failover'
|
||||
| otherwise
|
||||
-> failover'
|
||||
|
||||
@ -212,7 +210,7 @@ failoverMetrics fLbl failoverMetricsFailover@Failover{..} = Metric $ do
|
||||
now <- liftIO $ getTime Monotonic
|
||||
cTime <- liftIO getPOSIXTime
|
||||
|
||||
metrics <- atomically $ do
|
||||
atomically $ do
|
||||
foState <- readTVar failover
|
||||
labelsSeen' <- stateTVar labelsSeen $ \labelsSeen' -> labelsSeen'
|
||||
& ala Endo foldMap [ Map.insert failoverLabel failoverLastTest | FailoverItem{..} <- F.toList foState ]
|
||||
@ -228,8 +226,6 @@ failoverMetrics fLbl failoverMetricsFailover@Failover{..} = Metric $ do
|
||||
]
|
||||
]
|
||||
|
||||
return metrics
|
||||
|
||||
failoverActiveInfo = Info "uni2work_failover_active_bool"
|
||||
"Currently active item in the failover set"
|
||||
failoverLastTestInfo = Info "uni2work_failover_last_test_time"
|
||||
|
||||
Loading…
Reference in New Issue
Block a user