From 749b5fc6193d7aed761b0fb7a5996348a0306806 Mon Sep 17 00:00:00 2001
From: jonny <ga86lad@mytum.de>
Date: Fri, 31 Dec 2021 20:37:59 +0100
Subject: [PATCH] added / after scripts updated error message

---
 lib/Properties.hs | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/lib/Properties.hs b/lib/Properties.hs
index 73c6467..efc7e13 100644
--- a/lib/Properties.hs
+++ b/lib/Properties.hs
@@ -147,7 +147,7 @@ checkMapProperty p@(Property name _) = case name of
                 (not $ "/../" `isInfixOf` str) &&
                 (not $ "%" `isInfixOf` str) &&
                 (not $ "@" `isInfixOf` str))
-        $ forbid "only scripts hosted on static.rc3.world are allowed."
+        $ forbid "only scripts hosted on https://static.rc3.world/scripts/ are allowed."
     | name `elem` ["jitsiRoom", "bbbRoom", "playAudio", "openWebsite"
                   , "url", "exitUrl", "silent", "getBadge"]
           -> complain $ "property " <> name
@@ -348,7 +348,7 @@ checkIsRc3Url text=
 checkIsRc3ScriptUrl :: Text -> Bool 
 checkIsRc3ScriptUrl url = checkIsRc3Url url && case parseUri url of
   Nothing  -> False
-  Just (_,_,path) -> "/scripts" `isPrefixOf` path
+  Just (_,_,path) -> "/scripts/" `isPrefixOf` path
 
 -- | Checks a single (custom) property of a "normal" tile layer
 checkTileLayerProperty :: Property -> LintWriter Layer
-- 
GitLab