Make search query default to show if given (#561)

This allows for shorter permalinks for displaying a given package.
This commit is contained in:
Naïm Favier 2022-11-04 13:22:52 +01:00 committed by GitHub
parent 5bbe885b62
commit cf23c13a17
Failed to generate hash of commit

View file

@ -307,6 +307,9 @@ init args defaultNixOSChannel nixosChannels maybeModel =
, query =
args.query
|> Maybe.andThen Route.SearchQuery.searchQueryToString
|> \ x -> case x of
Just q -> Just q
Nothing -> args.show
, result = getField .result RemoteData.NotAsked
, show = args.show
, from =