add name to root query params

This commit is contained in:
Lucy Cifferello
2023-06-16 14:59:00 -06:00
parent 550890070e
commit dd4d8b2856

View File

@@ -3,9 +3,10 @@ import Startlude
import Yesod import Yesod
import Foundation import Foundation
import qualified Data.Text as T import qualified Data.Text as T
import Settings (AppSettings(registryHostname)) import Settings (AppSettings(registryHostname, marketplaceName))
getRootR :: HandlerFor RegistryCtx () getRootR :: HandlerFor RegistryCtx ()
getRootR = do getRootR = do
hostname <- getsYesod $ registryHostname . appSettings url <- getsYesod $ registryHostname . appSettings
redirect $ T.pack "https://marketplace.start9.com?api=" <> hostname name <- getsYesod $ marketplaceName . appSettings
redirect $ T.pack "https://marketplace.start9.com?api=" <> url <> T.pack "&name=" <> name