From 85f3053d852d15295a8e841668db603e2fee346f Mon Sep 17 00:00:00 2001 From: Vladimir Krutkin Date: Fri, 11 Oct 2024 14:40:17 +0300 Subject: [PATCH] Fix dashboard config `develop-assets` option --- hbs2-git-dashboard/app/GitDashBoard.hs | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/hbs2-git-dashboard/app/GitDashBoard.hs b/hbs2-git-dashboard/app/GitDashBoard.hs index 392e3caf..8701f408 100644 --- a/hbs2-git-dashboard/app/GitDashBoard.hs +++ b/hbs2-git-dashboard/app/GitDashBoard.hs @@ -394,8 +394,6 @@ runDashboardWeb WebOptions{..} = do runScotty :: DashBoardPerks m => DashBoardM m () runScotty = do - pno <- getHttpPortNumber - wo <- WebOptions <$> getDevAssets env <- ask @@ -407,6 +405,9 @@ runScotty = do run theDict conf + pno <- getHttpPortNumber + wo <- WebOptions <$> getDevAssets + flip runContT pure do void $ ContT $ withAsync updateIndexPeriodially void $ ContT $ withAsync runRPC @@ -659,7 +660,8 @@ theDict = do developAssetsEntry = do entry $ bindMatch "develop-assets" $ nil_ \case [StringLike s] -> do - pure () + devAssTVar <- lift $ asks _dashBoardDevAssets + atomically $ writeTVar devAssTVar (Just s) _ -> none