diff options
-rw-r--r-- | lib/Properties.hs | 27 |
1 files changed, 15 insertions, 12 deletions
diff --git a/lib/Properties.hs b/lib/Properties.hs index 51fa567..341426d 100644 --- a/lib/Properties.hs +++ b/lib/Properties.hs @@ -702,18 +702,21 @@ unwrapURI sym p@(Property name _) f g = unwrapString p $ \link -> do setProperty name uri f uri Left NotALink -> unwrapPath link g - Left err -> complain $ case err of - IsBlocked -> link <> " is a blocked site." - DomainDoesNotExist domain -> "The domain " <> domain <> " does not exist; \ - \please make sure it is spelled correctly." - SchemaDoesNotExist schema -> - "the URI schema " <> schema <> ":// cannot be used." - WrongScope schema allowed -> - "the URI schema " <> schema <> ":// cannot be used in property \ - \\"" <> name <> "\"; allowed " - <> (if length allowed == 1 then "is " else "are ") - <> intercalate ", " (fmap (<> "://") allowed) <> "." - VarsDisallowed -> "extended API links are disallowed in links" + Left err -> do + isLobby <- lintConfig configAssemblyTag <&> (== "lobby") + + (if isLobby then warn else complain) $ case err of + IsBlocked -> link <> " is a blocked site." + DomainDoesNotExist domain -> "The domain " <> domain <> " does not exist; \ + \please make sure it is spelled correctly." + SchemaDoesNotExist schema -> + "the URI schema " <> schema <> ":// cannot be used." + WrongScope schema allowed -> + "the URI schema " <> schema <> ":// cannot be used in property \ + \\"" <> name <> "\"; allowed " + <> (if length allowed == 1 then "is " else "are ") + <> intercalate ", " (fmap (<> "://") allowed) <> "." + VarsDisallowed -> "extended API links are disallowed in links" |