use globFilePackage in widgetFileReload and widgetFileNoReload

this will mean that files can be build from another directory whilst still finding the package's templates
This commit is contained in:
David Hewson 2020-08-07 13:22:55 +01:00
parent b73a95c8b6
commit 8069d42d90

View File

@ -130,7 +130,7 @@ warnUnlessExists :: Bool
-> Bool -- ^ requires toWidget wrap
-> String -> (FilePath -> Q Exp) -> Q (Maybe Exp)
warnUnlessExists shouldWarn x wrap glob f = do
let fn = globFile glob x
fn <- globFilePackage glob x
e <- qRunIO $ doesFileExist fn
when (shouldWarn && not e) $ qRunIO $ putStrLn $ "widget file not found: " ++ fn
if e