fix: non-exhaustive patterns
This commit is contained in:
parent
6a7442728f
commit
5bff34ed0a
@ -83,7 +83,7 @@ getEShowR tid ssh csh examn = do
|
|||||||
showCloseWidget = lecturerInfoShown
|
showCloseWidget = lecturerInfoShown
|
||||||
showAutoOccurrenceCalculateWidget = lecturerInfoShown
|
showAutoOccurrenceCalculateWidget = lecturerInfoShown
|
||||||
|
|
||||||
sumMaxPoints = sum [ fromRational examPartWeight * mPoints | Entity _ ExamPart{..} <- examParts, let Just mPoints = examPartMaxPoints ]
|
sumMaxPoints = sum [ fromRational examPartWeight * mPoints | Entity _ ExamPart{..} <- examParts, mPoints <- examPartMaxPoints ^.. _Just ]
|
||||||
|
|
||||||
noBonus = fromMaybe False $ do
|
noBonus = fromMaybe False $ do
|
||||||
guardM $ bonusOnlyPassed <$> examBonusRule
|
guardM $ bonusOnlyPassed <$> examBonusRule
|
||||||
|
|||||||
@ -249,8 +249,7 @@ examAutoOccurrence (hash -> seed) rule ExamAutoOccurrenceConfig{..} occurrences
|
|||||||
= Map.fromListWith Set.union
|
= Map.fromListWith Set.union
|
||||||
[ (map CI.mk $ unpack matriculation', Set.singleton uid)
|
[ (map CI.mk $ unpack matriculation', Set.singleton uid)
|
||||||
| (uid, (User{..}, Nothing)) <- Map.toList users
|
| (uid, (User{..}, Nothing)) <- Map.toList users
|
||||||
, let Just matriculation' = userMatrikelnummer
|
, matriculation' <- userMatrikelnummer ^.. _Just . filtered (not . null)
|
||||||
, not $ null matriculation'
|
|
||||||
]
|
]
|
||||||
in Map.mapKeysWith Set.union (take . F.minimum . Set.map length $ Map.keysSet matrUsers) matrUsers
|
in Map.mapKeysWith Set.union (take . F.minimum . Set.map length $ Map.keysSet matrUsers) matrUsers
|
||||||
_ -> Map.singleton [] $ Map.keysSet users
|
_ -> Map.singleton [] $ Map.keysSet users
|
||||||
|
|||||||
Reference in New Issue
Block a user